Creating the Import Records tool
In this first section, we'll build a Python Toolbox for the crime analysis tools that we'll create over the course of the next two chapters, and we'll create the Import Records tool. By now, you should be comfortable with the basic process of creating an ArcGIS Python Toolbox, so I will provide only a minimum set of instructions to create the toolbox. If needed, refer to the first chapter for the specifics of how to create an ArcGIS Python Toolbox.
The Import Records tool, which will be created in this section, will dynamically Import Records from an online, open records dataset provided by the city of Seattle, WA. This dataset will be accessed through the Socrata Open Data
API using the Python requests
module. For this tool, we'll include several parameters, including start and end dates to filter the records, a filter for the crime type, an output feature class where the records will be written, and an optional parameter to filter by police district. The...