0b0e5c5f92fe4ccbba32eec8c0bb4c22 - Anywhere.ArcGIS 1.6.1-dev60
Operations and data types used with the ArcGIS REST API.
PM> Install-Package Anywhere.ArcGIS -Version 1.6.1-dev60 -Source https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v3/index.json
> nuget.exe install Anywhere.ArcGIS -Version 1.6.1-dev60 -Source https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v3/index.json
> dotnet add package Anywhere.ArcGIS --version 1.6.1-dev60 --source https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v3/index.json
source https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v3/index.json
nuget Anywhere.ArcGIS ~> 1.6.1-dev60
Copy to clipboard
> choco install Anywhere.ArcGIS --version 1.6.1-dev60 --source https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v2
Import-Module PowerShellGet
Register-PSRepository -Name "0b0e5c5f92fe4ccbba32eec8c0bb4c22" -SourceLocation "https://www.myget.org/F/0b0e5c5f92fe4ccbba32eec8c0bb4c22/api/v2"
Install-Module -Name "Anywhere.ArcGIS" -RequiredVersion "1.6.1-dev60" -Repository "0b0e5c5f92fe4ccbba32eec8c0bb4c22" -AllowPreRelease
Copy to clipboard
Anywhere.ArcGIS
Use ArcGIS Server REST resources without an official SDK. This is a netstandard 2.1 library, it was ported from ArcGIS.PCL. It is not endorsed, affiliated or supported by Esri. Use v1.x of this library if you need to use the netstandard 2.0 version.
A typical use case would be the need to call some ArcGIS REST resource from server .NET code or maybe a console app. The features that this returns can be used directly as Esri JSON in JavaScript apps using the Esri JS API.
Works with secure and non-secure ArcGIS Server on premise / in the cloud, Portal for ArcGIS and ArcGIS Online. Also supports converting GeoJSON :left_right_arrow: ArcGIS Features.
Quickstart
If you are calling a REST operation you will need to create a gateway to manage the request. There are a few different ones but the most basic is called PortalGateway
and this can be used for connecting directly to services with ArcGIS Server.
Create an instance of that by specifying the root url of your server. The format of the root url is scheme://host:port/instance so a typical default ArcGIS Server for your local machine would be http://localhost:6080/arcgis, note that you do not need to include rest/services
in either the root url or your relative urls as it gets added automatically. One thing to look out for is that the url is case sensitive so make sure you enter it correctly.
var gateway = new PortalGateway("https://sampleserver3.arcgisonline.com/ArcGIS/");
// If you want to access secure resources then pass in a username / password
// this assumes the token service is in the default location for the ArcGIS Server
var secureGateway = new PortalGateway("https://sampleserver3.arcgisonline.com/ArcGIS/", "username", "password");
// Or use the static Create method which will discover the token service Url from the server Info endpoint
var autoTokenProviderLocationGateway = await PortalGateway.Create("https://sampleserver3.arcgisonline.com/ArcGIS/", "username", "password");
Now you have access to the various operations supported by it. For example to call a query against a service
var query = new Query("Earthquakes/EarthquakesFromLastSevenDays/MapServer/0".AsEndpoint())
{
Where = "magnitude > 4.0"
};
var result = await gateway.Query<Point>(query);
Capabilities
Supports the following as typed operations:
CheckGenerateToken
create a token automatically via anITokenProvider
Query
query a layer by attribute and / or spatial filters, also possible to doBatchQuery
QueryForCount
only return the number of results for the query operationQueryForIds
only return the ObjectIds for the results of the query operationQueryForExtent
return the bounding extent for the result of the query operationQueryAttachments
return attachments grouped by the source feature object Ids and global idQueryDomains
returns full domain information for the domains referenced by the layers in the serviceFind
search across n layers and fields in a serviceApplyEdits
post adds, updates and deletes to a feature service layerDeleteFeatures
delete features in a feature layer or tableGeocode
single line of input to perform a geocode using a custom locator or the Esri world locatorCustomGeocode
single line of input to perform a geocode using a custom locatorSuggest
lightweight geocode operation that only returns text results, commonly used for predictive searchingReverseGeocode
find location candidates for a input point locationSimplify
alter geometries to be topologically consistentProject
convert geometries to a different spatial referenceBuffer
buffers geometries by the distance requestedDescribeSite
returns a url for every service discoveredCreateReplica
create a replica for a layerUnregisterReplica
unregister a replica based on the IdDeleteAttachments
delete attachments that are associated with a featurePing
verify that the server can be accessedInfo
return the server information such as version and token authentication settingsDescribeLegends
return legend information of layersDescribeServices
return services information (name, sublayers etc.)DescribeService
return service information (name, sublayers etc.)DescribeLayer
return layer informationHealthCheck
verify that the server is accepting requestsGetFeature
return a feature from a map/feature serviceExportMap
get an image (or url to the image) of a service
REST admin operations:
PublicKey
- admin operation to get public key used for encryption of token requestsServiceStatus
- admin operation to get the configured and actual status of a serviceServiceReport
- admin operation to get the service reportStartService
- admin operation to start a serviceStopService
- admin operation to stop a serviceServiceStatistics
- admin operation to get the statistics of a service
There are also methods to add / update and download attachments for a feature and you can extend this library by writing your own operations.
Refer to the integration test project for more examples.
Can I help to improve it and/or fix bugs?
Absolutely! Please feel free to raise issues, fork the source code, send pull requests, etc.
No pull request is too small. Even whitespace fixes are appreciated. Before you contribute anything make sure you read CONTRIBUTING.
Installation
NuGet Package Manager
Install-Package Anywhere.ArcGIS
.NET CLI
dotnet add package Anywhere.ArcGIS
Paket CLI
paket add Anywhere.ArcGIS
You can also get the code from this site.
What do the version numbers mean?
Anywhere.ArcGIS uses Semantic Versioning.
Icon
Icon made by Freepik from www.flaticon.com
- .NETStandard 2.0: 2.0.0.0
OwnersDave Timmins |
AuthorsDave Timmins |
Project URLhttps://github.com/davetimmins/Anywhere.ArcGIS |
LicenseMIT |
TagsArcGIS ArcGISServer ArcGISOnline Esri REST netstandard anywhere GIS Mapping Map Location GeoLocation OAuth |
Info55 total downloads |
0 downloads for version 1.6.1-dev60 |
Download (117.52 KB) |
Found on the current feed only |
Package history
Version | Size | Last updated | Downloads | Mirrored? | |||
---|---|---|---|---|---|---|---|
2.0.1-dev170 | 131.88 KB | Tue, 26 Jul 2022 19:54:29 GMT | 0 | ||||
2.0.1-dev163 | 131.88 KB | Sat, 25 Sep 2021 00:02:25 GMT | 1 | ||||
2.0.0-dev162 | 131.64 KB | Sat, 25 Sep 2021 00:01:37 GMT | 0 | ||||
2.0.0-dev157 | 131.92 KB | Sun, 27 Sep 2020 23:18:46 GMT | 1 | ||||
2.0.0-dev156 | 132.05 KB | Sun, 27 Sep 2020 23:17:20 GMT | 1 | ||||
1.12.0-dev155 | 128.29 KB | Fri, 26 Jun 2020 04:30:58 GMT | 0 | ||||
1.12.0-dev153 | 128.3 KB | Thu, 04 Jun 2020 21:08:08 GMT | 0 | ||||
1.12.0-dev152 | 127.9 KB | Wed, 03 Jun 2020 00:26:58 GMT | 2 | ||||
1.12.0-dev149 | 127.89 KB | Wed, 03 Jun 2020 00:03:12 GMT | 1 | ||||
1.11.1-dev144 | 126.85 KB | Wed, 22 Apr 2020 22:55:35 GMT | 0 | ||||
1.11.0-dev143 | 126.84 KB | Wed, 11 Mar 2020 21:35:40 GMT | 0 | ||||
1.11.0-dev142 | 127.89 KB | Thu, 20 Feb 2020 18:31:02 GMT | 0 | ||||
1.11.0-dev135 | 127.72 KB | Mon, 09 Sep 2019 20:10:52 GMT | 0 | ||||
1.11.0-dev131 | 127.71 KB | Mon, 09 Sep 2019 20:06:08 GMT | 0 | ||||
1.10.0-dev130 | 127.71 KB | Mon, 09 Sep 2019 20:05:03 GMT | 1 | ||||
1.10.0-dev127 | 127.71 KB | Mon, 09 Sep 2019 20:00:40 GMT | 0 | ||||
1.10.0-dev124 | 127.72 KB | Mon, 09 Sep 2019 19:58:54 GMT | 1 | ||||
1.10.0-dev123 | 126.71 KB | Mon, 09 Sep 2019 19:56:00 GMT | 0 | ||||
1.10.0-dev121 | 126.7 KB | Mon, 09 Sep 2019 19:48:11 GMT | 0 | ||||
1.10.0-dev118 | 124.63 KB | Wed, 31 Jul 2019 19:52:25 GMT | 0 | ||||
1.10.0-dev112 | 124.38 KB | Thu, 18 Jul 2019 21:11:35 GMT | 0 | ||||
1.10.0-dev111 | 123.61 KB | Thu, 18 Jul 2019 21:07:06 GMT | 0 | ||||
1.9.2-dev110 | 123.61 KB | Thu, 18 Jul 2019 21:05:22 GMT | 1 | ||||
1.9.2-dev109 | 123.23 KB | Thu, 18 Jul 2019 20:52:07 GMT | 1 | ||||
1.9.2-dev108 | 123.23 KB | Tue, 28 May 2019 20:57:40 GMT | 1 | ||||
1.9.2-dev107 | 122.21 KB | Sun, 14 Apr 2019 19:20:36 GMT | 0 | ||||
1.9.1 | 122.24 KB | Thu, 11 Apr 2019 22:05:43 GMT | 0 | ||||
1.9.1-dev99 | 122.2 KB | Wed, 28 Nov 2018 23:59:19 GMT | 1 | ||||
1.9.1-dev106 | 122.21 KB | Fri, 12 Apr 2019 03:43:09 GMT | 0 | ||||
1.9.1-dev105 | 122.22 KB | Thu, 11 Apr 2019 20:33:33 GMT | 1 | ||||
1.9.0-dev98 | 122.21 KB | Wed, 14 Nov 2018 21:51:41 GMT | 0 | ||||
1.9.0-dev92 | 122.21 KB | Fri, 02 Nov 2018 17:45:44 GMT | 0 | ||||
1.8.1-dev91 | 122.21 KB | Fri, 02 Nov 2018 17:43:15 GMT | 1 | ||||
1.8.1-dev86 | 122.19 KB | Thu, 18 Oct 2018 01:07:17 GMT | 1 | ||||
1.8.0-dev84 | 122.05 KB | Mon, 17 Sep 2018 23:34:21 GMT | 0 | ||||
1.8.0-dev80 | 122.06 KB | Sun, 09 Sep 2018 19:50:44 GMT | 0 | ||||
1.7.1-dev79 | 122.07 KB | Wed, 05 Sep 2018 22:15:48 GMT | 1 | ||||
1.7.1-dev76 | 120.64 KB | Mon, 27 Aug 2018 19:34:19 GMT | 2 | ||||
1.7.1-dev71 | 119.91 KB | Thu, 23 Aug 2018 23:03:38 GMT | 1 | ||||
1.7.1-dev70 | 119.88 KB | Mon, 20 Aug 2018 04:37:48 GMT | 1 | ||||
1.7.1-dev69 | 119.24 KB | Thu, 16 Aug 2018 20:13:30 GMT | 0 | ||||
1.7.0-dev65 | 119.04 KB | Thu, 02 Aug 2018 00:48:42 GMT | 1 | ||||
1.6.1-dev64 | 119.02 KB | Thu, 02 Aug 2018 00:27:15 GMT | 1 | ||||
1.6.1-dev63 | 118.44 KB | Thu, 02 Aug 2018 00:22:01 GMT | 0 | ||||
1.6.1-dev60 | 117.52 KB | Sun, 29 Jul 2018 22:38:51 GMT | 0 | ||||
1.6.1-dev59 | 117.36 KB | Tue, 24 Jul 2018 01:27:42 GMT | 1 | ||||
1.6.0-dev55 | 117.32 KB | Mon, 11 Jun 2018 17:39:36 GMT | 0 | ||||
1.6.0-dev54 | 117.32 KB | Sun, 10 Jun 2018 23:23:35 GMT | 0 | ||||
1.5.0-dev50 | 117.12 KB | Fri, 08 Jun 2018 00:55:41 GMT | 0 | ||||
1.5.0-dev49 | 117.03 KB | Thu, 31 May 2018 20:55:33 GMT | 1 | ||||
1.5.0-dev48 | 115.34 KB | Thu, 24 May 2018 03:48:18 GMT | 0 | ||||
1.5.0-dev47 | 114.73 KB | Mon, 07 May 2018 23:02:47 GMT | 0 | ||||
1.4.0-dev46 | 114.73 KB | Mon, 07 May 2018 23:01:26 GMT | 2 | ||||
1.4.0-dev42 | 114.55 KB | Mon, 12 Mar 2018 22:32:06 GMT | 1 | ||||
1.3.1-dev41 | 114.51 KB | Mon, 05 Mar 2018 20:42:49 GMT | 5 | ||||
1.3.1-dev36 | 114.47 KB | Sat, 03 Mar 2018 18:52:57 GMT | 3 | ||||
1.3.0-dev35 | 114.13 KB | Fri, 26 Jan 2018 01:37:35 GMT | 2 | ||||
1.3.0-dev31 | 114.38 KB | Thu, 25 Jan 2018 23:43:21 GMT | 4 | ||||
1.3.0-dev30 | 114.36 KB | Thu, 18 Jan 2018 17:56:07 GMT | 3 | ||||
1.2.1-dev26 | 112.34 KB | Mon, 15 Jan 2018 23:55:04 GMT | 1 | ||||
1.2.0-dev22 | 112.22 KB | Mon, 15 Jan 2018 18:45:49 GMT | 2 | ||||
1.1.0-dev19 | 84.72 KB | Mon, 11 Dec 2017 19:18:17 GMT | 2 | ||||
1.0.0-dev15 | 84.72 KB | Mon, 11 Dec 2017 19:13:27 GMT | 2 | ||||
1.0.0-dev11 | 84.39 KB | Tue, 14 Nov 2017 18:03:01 GMT | 4 |