
Download the ArcGISAFP_01.zip folder. It is important that you unzip the folder to the root of the C drive.
Download the agol_trial_link.txt from Resources.
Download the files from Resources (download_pyscripter.txt and api_conda_pip_install.txt) for links.
Download arcgis_api_overview.png and managers.txt
A brief overview of the content in this section.
In this video we will add a Shapefile item to our ArcGIS Online content. We will use the minimum amount of parameters necessary to achieve this. The Shapefile components (.shp, .shx, .dbf, .prj) must be in a zipped forder for the API to add as an item to your content. The add function in the ContentManager module returns the Item object for the created item.
In this video we will publish the Shapefile item we added in the Add a Shapefile without Item Properties video. We will use the get function from the ContentManager module to access the Shapefile Item object, and the use the item object to publish the Shapefile as a Hosted Feature Service. We will also use the publish_parameters parameter with the publish function and assess the output.
We will combine the first two videos in this section into one workflow, but this time we will use the item_properties parameter and set properties when we add a Shapefile as a content Item. This video will add a Shapefile as an Item and chain that item into publishing as a Hosted Feature Service.
So far we have added two Shapefiles and published to two separate Hosted Feature Services. We have a zipped folder that contains four Shapefiles, we will add as a Shapefile item and publish, all four are represented in four different layers in the Hosted Feature Service.
In this video we will add a CSV (comma separated value) file as an item in ArcGIS Online and publish the CSV item as a Hosted Table.
Let's create and empty Feature Service without a Feature Layer or Table. In The Feature Layer Object section we will add a Feature Layer, and the in the Attributes, Geometries, and the FeatureSet section we will add some records.
In this lesson we will take a look at the ItemProperties class which can be used instead of a dictionary when defining the item_properties parameter for add/update methods, and the ItemTypeEnum class that provides access to the correct text for each item type.
In this lesson we will create a folder in our ArcGIS Online. Folders are a great way to organize content items per user.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for folders.
In this lesson we will create a folder in our ArcGIS Online. Folders are a great way to organize content items per user.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for managing folders folders.
In this video we will move some Feature Services into our newly created National & Regional Datasets folder.
In this video we will use the User object to list or custom folders that the current logged in user has connected with their account.
In this lesson we will get a list of Folders that belong to the logged-in user.
In this lesson we will rename a user Folder.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for folders. From 3.0.0 we rename using the Folder object.
In this lesson we will rename a user Folder.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for folders. From 3.0.0 we rename using the Folder object.
In this lesson we will delete a Folder associated with a user.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for folders. From 3.0.0 we delete a folder using the Folder object.
In this lesson we will delete a Folder associated with a user.
Note: from version 2.3.0 the Folder object was introduced to replace using the ContentManager for folders. From 3.0.0 we delete a folder using the Folder object.
In this video we will move a Content Item from a folder back into the home folder. NOTE: This video was added after the first publication of the course. Make sure to re-download the ArcGISAFP_01.zip from the Course Setup & Data video in the Introduction section.
In this lesson we will take a look at the properties property available with a Folder object. The properties property is a dictionary containing four key, value pairs for username, id, title, created.
In this lesson we will use the add() method for a Folder object to add a Shapefile item directly into a folder. We will use the ItemProperties class to define the title and item_type.
In this lesson we will take a look at the list() method available with a Folder object. The list method returns a generator object containing item objects. The item objects represents the items in the folder of interest in ArcGIS Online.
In this video we will create two Groups using the create() function from the GroupManager module, one using the two required parameters; title and tags, and a second Group using some optional parameters. The optional parameters available are listed and discussed.
In this video we will access the properties associated with a Group object.
An Item object has a share function that can be used to share the Item into a Group, we will share an individual item to a Group and then share all items from a specified folder into a Group.
In this video we will unshare a content item from a Group
In the Access a Group Item and View Properties video we printed the properties to screen, in this video we will look at updating some properties and show the updates in ArcGIS Online
In this lesson we will take a look at the add() method available from the SharingGroupManager to add an item into a Group. The SharingManager is a property of the Item object via the sharing property, which provides access to the SharingGroupManager via the SharingManager group property. Makes sense? Watch the video for more clarity.
NOTE: The Item object share() method is deprecated in 2.3.0 and removed in 3.0.0. The video shows the new age for sharing items into a group.
Prevent a Group from being accidentally deleted.
In this lesson we will take a look at the remove() method available from the SharingGroupManager to remove an item from a Group. The SharingManager is a property of the Item object via the sharing property, which provides access to the SharingGroupManager via the SharingManager group property. Makes sense? Watch the video for more clarity.
NOTE: The Item object unshare() method is deprecated in 2.3.0 and removed in 3.0.0. The video shows the new age for unsharing items into a group.
The get_member() method for a Group object returns a dictionary detailing the usernames of the Group owner, users, and admins.
The user_list() mthod for a Group object returns a dictionary with information about the Group owner and the users. It returns more detailed information about each user than the simple usernames returned in the get_members() method.
The notify() method for a Group object allows you to send notifications and emails to members of the Group.
The delete() method for a Group object can be used to delete a Group permanently. This does not delete content items from AGOL, these are still available. What happens if you call the delete() method on a Group that has delete protection enabled?
In this video we will access an Item objects properties for a Feature Service and print to screen.
We will update an Item object's properties and show the updated properties in ArcGIS Online
The add_comment() method for an Item object allows you to add a comment to the item's page on ArcGIS Online if comments are enabled for the item.
The protect() method for an Item object allows you to prevent the Item from accidentally being deleted.
The update_thumbnail() method enables you to add a thumbnail for an item of content.
The export() method for an Item object allows you to export from a Hosted Service and create a content item as various types such as a Shapefile in this example.
You can use the download() method for an Item object to download data to disk. You would use the export() and download() methods together to achieve successful download of data.
The usage() methods enables you to access the usage metrics for an Item.
In this lesson we will look at sharing content publicly, within the organization, and with the owner of the Item.
Note: as of 2.3.0 the item object share() method is deprecated, and removed as of 3.0.0. There is a new item object sharing property that accesses a SharingManager to provide users the ability to control how an item is shared.
As of version 2.3.0 the API introduced the SharingManager along with the SharingLevel class. We will take a look at both of these in this lesson. The SharingManager is accessed via the Item object.
Note: the SharingManager replaces the Item object share() method with is deprecated as of 2.3.0 and removed as of 3.0.0
In this lesson we will take a look at the Item object copy() method. We will focus on copying Feature Services. There is a catch with the copy() method, it does not create a standalone hosted Feature Service as the copy, but a reference back to the original it was copied from.
In this lesson we will take a look at the copy_feature_layer_collection() method available with an Item object that represents a Feature Service. Unlike the copy() method, the copy_feature_layer_collection() method creates a standalone hosted Feature Services, but, it does not copy data, it only creates the layers using the same schema without any records.
In this lesson we will take at the copy_item() method available with the Item object. The copy_item() is quite similar to the copy() method with hosted feature services in that it produces a shallow copy referencing back to the original data. Any edits in one are reflected in the other.
In this video we will access an Item as a Feature Layer Collection object, which represents a Hosted Feature Service, and print the properties to screen.
We will look at updating a selection of Feature Layer Collection properties.
In this video we will look at updating the capabilities that can be set for a Feature Layer Collection such as Edit, Update, and Delete.
With Editing capabilities set, you can enable Editor Tracking for each Feature Layer in the Feature Layer Collection
The first course of its kind on Udemy relating to the ArcGIS API for Python. This introductory course will provide you with a solid foundation to begin automating content management workflows and tasks with ArcGIS Online (or Portal). We will only use the ArcGIS API for Python throughout the course, and the standard Python library modules json, csv, and datetime where required. You can sign up for a free 21-day trial of ArcGIS Online/ArcGIS Pro that includes 2 Creator and 3 viewer licenses along with 400 in credits, which is well beyond the minor credit usage this course will use (approx 0.6 storage credit per day).
Automation is a hot topic for the Esri ArcGIS suite of software. Automating workflows in ArcGIS can significantly improve workflow efficiencies to witness time and cost saving. Knowledge of the ArcGIS API for Python will enhance your career prospects. Although this course focuses on Content Management as the main topic, it can also be considered as an introduction to the ArcGIS API for Python.
We will begin the journey with an overview of the components of the API used throughout the course and how to use the GIS class as the entry to your organizations ArcGIS Online via the API, before diving into code and scripts.
Our GIS needs some data! We will accomplish adding a set of Shapefiles and a CSV file as Content Items and publish these as Hosted Feature Services and a Hosted Table.
Folders are a great way to organize your content per user. We will create a couple of Folders and move created content into them. We will look at a selection of functions available via the ContentManager module to create, rename, and delete folders amongst other actions.
While folders are a great way to organize content per user, Groups can be used to organize and control access to data and provide security of the data across the Organization by granting access to specified users to view and interact with the content assigned to the Group. We will create a Group and look at accessing and updating the Group properties along with adding and removing content from a Group. We will take a look at a handful of methods available with a Group object such as adding/removing users, and prevent a Group from being delete.
ArcGIS Online content items have properties that assign descriptive meaning along with control configurations for that item. We will take a look at the properties for a Hosted Feature Service and Table, and show how to update certain properties with the API, and we will see how these updated are reflected in ArcGIS Online.
We will have a look at properties for a Feature Layer Collection object which represents the Feature Service. A Feature Service has settings and capabilities and we will see how we can manipulate these with the API. We can use the ArcGIS API for Python to set, turn on, and turn off various settings and capabilities such as editing and enabling editor tracking, and allowing users to extract the data in various file formats.
Continuing with accessing and updating properties, we will take a look at the properties associated with a Feature Layer and a Table Layer and how we can update the properties for these two. We will look at how to enable attachments for both.
Throughout the course we use a content items id to access the various item types. We will show the search capabilities associated with the ArcGIS API for Python and how we can search for content within the Organization and within and individual Group.
We will finish up with a some ContentManager methods that were unused through the course but are important to know, and also provide practical, real-life, examples of using the ArcGIS API for Python for Content Management.
Newly added material - The RecycleBin, SharingManager, SharingGroupManager and more!
Your course instructor, Glen Bambrick, has over 17 years' experience with GIS and geospatial data, and has implemented standardized workflows utilizing the ArcGIS API for Python to great affect. In this course he will introduce you to the ArcGIS for Python API and take you through some common tasks with a focus on Content Management.
By the end of this course... you will be fully armed with the capability to start using the ArcGIS for Python API with your own workflows for Content Management. This course will spark your imagination to what can be achieved and give you a solid footing to begin making the ArcGIS for Python API a part of your daily endeavors for automating those repetitive tasks relating to ArcGIS Online. You will be able to add and create content, Folders, and Groups, and alter the properties and settings associated with each. You will be able to access and manipulate the JSON behind the scenes for Feature Services, Feature Layers and Tables.