Skip to content

Commit

Permalink
refactor(explorer): slide headings up
Browse files Browse the repository at this point in the history
this shows the parameters in the table of contents
  • Loading branch information
steveoh committed Nov 27, 2023
1 parent 6841134 commit 941095e
Show file tree
Hide file tree
Showing 8 changed files with 61 additions and 41 deletions.
2 changes: 0 additions & 2 deletions src/explorer/src/components/parameters/Callback.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
##### callback

The callback function to execute for cross domain javascript calls (jsonp). This API supports CORS and does not recommend the use of callback and jsonp.

- **Type**: `string`
2 changes: 0 additions & 2 deletions src/explorer/src/components/parameters/OutputFormat.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
##### format

There are three output formats for the result object. The default being empty. `esrijson` will parse into an [esri.Graphic](https://developers.arcgis.com/javascript/latest/api-reference/esri-Graphic.html) for mapping purposes and `geojson` will format as a [Feature](https://geojson.org/). If this value is omitted, the default json will be returned.

- **Type**: `string`
Expand Down
4 changes: 1 addition & 3 deletions src/explorer/src/components/parameters/SpatialReference.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
##### spatialReference

The spatial reference defines how the coordinates will represent a location on the earth defined by how the round earth was made flat. The well known id's (WKID) of different coordinate systems define if the coordinates will be stored as degrees of longitude and latitude, meters, feet, etc. This endpoint supports the WKIDs from the [Geographic Coordinate System](https://pro.arcgis.com/en/pro-app/latest/help/mapping/properties/pdf/geographic_coordinate_systems.pdf) reference and the [Projected Coordinate System](https://pro.arcgis.com/en/pro-app/latest/help/mapping/properties/pdf/projected_coordinate_systems.pdf) reference. UTM Zone 12 N, with the WKID of **26912**, is the default. This coordinate system is the most accurate reflection of Utah. It is recommended to use this coordinate system if length and area calculations are important as other coordinate systems will skew the truth.

- **Type**: `number`
Expand All @@ -15,7 +13,7 @@ The spatial reference defines how the coordinates will represent a location on t

:::

###### Reference Information
##### Reference Information

- [What are map projections?](https://desktop.arcgis.com/en/arcmap/latest/map/projections/what-are-map-projections.htm)
- [What are projected coordinate systems?](https://desktop.arcgis.com/en/arcmap/latest/map/projections/about-projected-coordinate-systems.htm)
Expand Down
24 changes: 15 additions & 9 deletions src/explorer/src/content/docs/docs/v1/endpoints/geocoding.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@ Geocoding allows you to get the geographic location (i.e., the geographical coor

:::

### URI Format
## URI Format

<Uri verb="GET" endpoint="geocode" properties={["street", "zone"]} />

### Parameters
## Parameters

<Card title="Required Path parameters" icon="approve-check">

##### street
### street

A Utah street address. A valid mailing address or structure does not need to exist at the input street to find a match. If the house number exists in the range of the street, a coordinate will be extrapolated from the road centerlines.

Expand All @@ -43,7 +43,7 @@ For the best geocoding results, omit sub address values from your street input,
- **Type**: `string`
- **Example**: `326 east south temple st`

##### zone
### zone

A Utah municipality name or a 5 digit zip code.

Expand All @@ -53,39 +53,39 @@ A Utah municipality name or a 5 digit zip code.
</Card>
<Card title="Optional Query parameters" icon="setting">

##### acceptScore
### acceptScore

Every street and zone geocode will return a score for the match on a scale from 0-100. The score is a rating of how confident the system is in the choice of coordinates based on the input. For example, misspellings in a street name, omitting a street type when multiple streets with the same name exist, or omitting a street direction when the street exists in multiple address system quadrants will cause the result to lose points. Depending on your needs, you may need to limit the score the system will return. The default value of `70` will give acceptable results. If you need extra control, use the suggest and scoreDifference options

- **Type**: `number`
- **Default**: `70`
- **Can be one of**: `0-100`

##### pobox
### pobox

This option determines if the system should find a location for P.O. Box addresses. The default value of `true`, will return a location for a P.O. Box only when the input zone is a 5 digit zip code. The result will be where the mail is delivered. This could be a traditional post office, community post office, university, etc. When analyzing where people live, P.O. Box information will skew results since there is no correlation between where mail is delivered and where the owner of the mail resides.

- **Type**: `boolean`
- **Default**: `true`
- **Can be one of**: `true`, `false`

##### locators
### locators

The locators are the search engine for address data. There are three options, The default value of `all` will use the highest score from the [address point](https://gis.utah.gov/data/location/address-data/#AddressPoints) and [road centerline](https://gis.utah.gov/data/transportation/roads-system/#RoadCenterlines) data and provide the best match rate. Address point locations are used in the event of a tie. Address points are a work in progress with the counties to map structures or places where mail is delivered. Road centerlines are a dataset with every road and the range of numbers that road segment contains.

- **Type**: `string`
- **Default**: `all`
- **Can be one of**: `all`, `addressPoints`, `roadCenterlines`

##### suggest
### suggest

The default value of 0 will only return the highest match. To include more address candidates, set this value between 1-5. The candidates respect the `acceptScore` option.

- **Type**: `number`
- **Default**: `0`
- **Can be one of**: `0-5`

##### scoreDifference
### scoreDifference

When `suggest` is set to the default value of `0`, the difference in score between the top match and the next highest match is calculated and returned on the result object. This can help determine if there was a tie. The system will arbitrarily choose one result since they will have the same score. If the scoreDifference response value is `0`, you can repeat the geocode with `suggest` > 0 and investigate the results.

Expand All @@ -97,10 +97,16 @@ A common scenario to cause a tie is when an input address of `100 main street` i
- **Default**: `all`
- **Can be one of**: `all`, `addressPoints`, `roadCenterlines`

### spatialReference

<SpatialReference />

### format

<OutputFormat />

### callback

<Callback />

</Card>
Expand Down
18 changes: 12 additions & 6 deletions src/explorer/src/content/docs/docs/v1/endpoints/milepost.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,26 +14,26 @@ import Callback from "../../../../../components/parameters/Callback.mdx";

Geocoding allows you to get the geographic location (i.e., the geographical coordinates) from text. This UGRC API endpoint allows you to get the coordinates of a highway number and milepost. This endpoint uses the UDOT Roads and Highways system as its authoritative data source.

### URI Format
## URI Format

<Uri
verb="GET"
endpoint="geocode/milepost"
properties={["route", "milepost"]}
/>

### Parameters
## Parameters

<Card title="Required Path parameters" icon="approve-check">

##### route
### route

A Utah highway number. Omit the interstate or state route prefix.

- **Type**: `number`
- **Example**: `15`

##### milepost
### milepost

A milepost number along the route. The precisions is 1/1000 (3 decimal places) of a mile which is approximately 5 feet.

Expand All @@ -43,7 +43,7 @@ A milepost number along the route. The precisions is 1/1000 (3 decimal places) o
</Card>
<Card title="Optional Query parameters" icon="setting">

##### side
### side

Mileposts, on divided highways, have different locations when traveling along the route in the increasing or decreasing direction. When traveling in the increasing direction milepost values are getting larger and when traveling on the decreasing side of the divided highway, the milepost values are getting smaller.

Expand All @@ -55,7 +55,7 @@ Side only applies to divided highways.
- **Default**: `increasing`
- **Can be one of**: `increasing`, `decreasing`

##### fullRoute
### fullRoute

Advanced clients who know the full route name, e.g., `0015PC30554` as it is stored in the UDOT Roads and Highway system can enable this flag and search using the full route name.

Expand All @@ -67,10 +67,16 @@ When this option is `true` the `route` path parameter changes from a number to a
- **Default**: `false`
- **Can be one of**: `true`, `false`

### spatialReference

<SpatialReference />

### format

<OutputFormat />

### callback

<Callback />

</Card>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,22 +18,22 @@ Reverse geocoding allows you to get what is at the geographic location (i.e., th
This endpoint returns an address along a road segment, however, there may be no structure or mail delivery at the address.
:::

### URI Format
## URI Format

<Uri verb="GET" endpoint="geocode/reverse" properties={["x", "y"]} />

### Parameters
## Parameters

<Card title="Required Path parameters" icon="approve-check">

##### x
### x

A number representing the longitude, easting, or horizontal value of a coordinate.

- **Type**: `number`
- **Example**: `374165.98`

##### y
### y

A number representing the latitude, northing, or vertical value of a coordinate.

Expand All @@ -43,16 +43,20 @@ A number representing the latitude, northing, or vertical value of a coordinate.
</Card>
<Card title="Optional Query parameters" icon="setting">

##### distance
### distance

The distance, in meters, from the input coordinate to search for a street address.

- **Type**: `number`
- **Default**: `5`
- **Can be one of**: `0-2000`

### spatialReference

<SpatialReference />

### callback

<Callback />

</Card>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,22 @@ Reverse geocoding allows you to get what is at the geographic location (i.e., th
This endpoint returns an address along a road segment, however, there may be no structure or mail delivery at the address.
:::

### URI Format
## URI Format

<Uri verb="GET" endpoint="geocode/milepost" properties={["x", "y"]} />

### Parameters
## Parameters

<Card title="Required Path parameters" icon="approve-check">

##### x
### x

A number representing the longitude, easting, or horizontal value of a coordinate.

- **Type**: `number`
- **Example**: `442300.87`

##### y
### y

A number representing the latitude, northing, or vertical value of a coordinate.

Expand All @@ -42,32 +42,36 @@ A number representing the latitude, northing, or vertical value of a coordinate.
</Card>
<Card title="Optional Query parameters" icon="setting">

##### buffer
### buffer

The buffer radius, in meters, from the input coordinate to search for a street address.

- **Type**: `number`
- **Default**: `100`
- **Can be one of**: `0-200`

##### includeRampSystem
### includeRampSystem

To include ramps, collectors, and federal aide routes features in a reverse route and milepost query set this to `true`.

- **Type**: `boolean`
- **Default**: `false`
- **Can be one of**: `true`, `false`

##### suggest
### suggest

The default value of 0 will only return the closest match. To include more route and milepost candidates, set this value between 1-5. The candidates will all be within the `buffer` radius.

- **Type**: `number`
- **Default**: `0`
- **Can be one of**: `0-5`

### spatialReference

<SpatialReference />

### callback

<Callback />

</Card>
Expand Down
20 changes: 13 additions & 7 deletions src/explorer/src/content/docs/docs/v1/endpoints/searching.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,22 +14,22 @@ import Callback from "../../../../../components/parameters/Callback.mdx";

Searching allows you to find information in more than 1,000,000 rows of spatial [State Geographic Information Datasource](https://gis.utah.gov/sgid/), SGID, data without expensive software or licensing. With over 300 tables of real-world Utah data that you can run queries against in the SGID, the possibilities can be a little overwhelming. But the searching endpoint opens the opportunity for serious information extraction. This UGRC API endpoint allows you to get geometries and attributes of any table in the [OpenSGID](https://gis.utah.gov/sgid/#open-sgid).

### URI Format
## URI Format

<Uri verb="GET" endpoint="search" properties={["table", "fields"]} />

### Parameters
## Parameters

<Card title="Required Path parameters" icon="approve-check">

##### table
### table

The schema qualified name of an OpenSGID table. Read the [getting connected guide](https://gis.utah.gov/sgid/open-sgid/) to start browsing the OpenSGID.

- **Type**: `string`
- **Example**: `boundaries.county_boundaries`

##### fields
### fields

A comma separated string of fields to return.

Expand All @@ -46,33 +46,39 @@ There are a few special tokens to access geometry data.
</Card>
<Card title="Optional Query parameters" icon="setting">

##### predicate
### predicate

The predicate allows you to filter the result. Use simple PostgreSQL predicates.

- **Type**: `string`
- **Default**: `1=1`
- **Example**: `UPPER(name) like '%K'`

##### geometry
### geometry

The `point`, `polyline`, `polygon`, `multipoint`, or `envelope` geometry types used for spatial queries. These geometries are denoted as `geometryType:ArcGIS Server JSON representation`. eg:

- **Type**: `string`
- **Example**: `point:{"x":464912.85,"y":4497772.12,"spatialReference":{"wkid":26912}}`

##### buffer
### buffer

A distance in meters to buffer the input geometry. 2000 meters is the maximum buffer.

- **Type**: `integer`
- **Default**: `0`
- **Example**: `10`

### spatialReference

<SpatialReference />

### format

<OutputFormat />

### callback

<Callback />

</Card>
Expand Down

0 comments on commit 941095e

Please sign in to comment.