| Name | earthranger-client JSON |
| Version |
1.8.0
JSON |
| download |
| home_page | None |
| Summary | Client for EarthRanger API |
| upload_time | 2025-09-03 22:45:34 |
| maintainer | None |
| docs_url | None |
| author | None |
| requires_python | >=3.8 |
| license | Apache-2.0 |
| keywords |
earthranger
api
|
| VCS |
 |
| bugtrack_url |
|
| requirements |
No requirements were recorded.
|
| Travis-CI |
No Travis.
|
| coveralls test coverage |
No coveralls.
|
# EarthRanger Client
## Introduction
[EarthRanger](https://www.earthranger.com/) is a software solution that helps protected area managers, ecologists, and wildlife biologists make informed operational decisions for wildlife conservation.
The earthranger-client (er-client) is a Python library for accessing the EarthRanger HTTP API. It simplifies interaction with the API by abstracting away the complexity of resource-based endpoints and provides multi-threaded and async capabilities for improved performance.
## Uses of er-client
* Extracting data for analysis
* Importing ecological or other historical data
* Integrating a new field sensor type. If you do and will be supporting multiple ER sites, contact us to talk about our Gundi integrations platform
* Performing external analysis that results in publishing an Alert on the ER platform.
## Quick Start
see simple-example.py
## Installation
From pypi
```
pip install earthranger-client
```
## Usage
In your code, import the library and create an instance of the client.
```
from erclient import ERClient
client = ERClient(service_root="https://sandbox.pamdas.org/api/v1.0", username="", password="")
```
## Async Support
We also offer an async client (asyncio).
Disclaimer: The async client current capabilities are limited to:
* Posting Sensor Observations (a.k.a Positions)
* Posting Events (a.k.a Reports)
* Posting Event Attachments
* Posting Camera Trap Reports
* Getting Event Types
* Getting Events
* Getting Observations
* Getting Subject Groups
* Getting Feature groups
* Getting Sources
* Getting Source Assignments (aka SubjectSource resources)
```
from erclient import AsyncERClient
# You can use it as an async context-managed client
async with AsyncERClient(service_root="https://sandbox.pamdas.org/api/v1.0", username="", password="") as client:
await self.er_client.post_sensor_observation(position)
await client.post_report(report)
await self.er_client.post_camera_trap_report(camera_trap_payload, file)
...
async with AsyncERClient(service_root="https://sandbox.pamdas.org/api/v1.0", username="", password="") as client:
async for observation in client.get_observations(start="2023-11-10T00:00:00-06:00"):
print(observation)
...
# Or create an instance and close the client explicitly later
client = AsyncERClient(service_root="https://sandbox.pamdas.org/api/v1.0", username="", password="")
await self.er_client.post_sensor_observation(position)
await client.post_report(report)
await self.er_client.post_camera_trap_report(camera_trap_payload, file)
...
await client.close() # Close the session used to send requests to ER API
```
Raw data
{
"_id": null,
"home_page": null,
"name": "earthranger-client",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "EarthRanger, api",
"author": null,
"author_email": "EarthRanger <opensource@earthranger.com>",
"download_url": "https://files.pythonhosted.org/packages/75/b9/be19c113166182bb1f21fc00e1c736b8adfca6fdb16b176a5817e17c8518/earthranger_client-1.8.0.tar.gz",
"platform": null,
"description": "# EarthRanger Client\n## Introduction\n[EarthRanger](https://www.earthranger.com/) is a software solution that helps protected area managers, ecologists, and wildlife biologists make informed operational decisions for wildlife conservation.\n\nThe earthranger-client (er-client) is a Python library for accessing the EarthRanger HTTP API. It simplifies interaction with the API by abstracting away the complexity of resource-based endpoints and provides multi-threaded and async capabilities for improved performance.\n\n## Uses of er-client\n* Extracting data for analysis\n* Importing ecological or other historical data\n* Integrating a new field sensor type. If you do and will be supporting multiple ER sites, contact us to talk about our Gundi integrations platform\n* Performing external analysis that results in publishing an Alert on the ER platform.\n\n## Quick Start\n\nsee simple-example.py\n\n## Installation\nFrom pypi\n```\npip install earthranger-client\n```\n\n## Usage\nIn your code, import the library and create an instance of the client.\n\n```\nfrom erclient import ERClient\n\nclient = ERClient(service_root=\"https://sandbox.pamdas.org/api/v1.0\", username=\"\", password=\"\")\n```\n## Async Support\nWe also offer an async client (asyncio).\n\nDisclaimer: The async client current capabilities are limited to:\n* Posting Sensor Observations (a.k.a Positions)\n* Posting Events (a.k.a Reports)\n* Posting Event Attachments\n* Posting Camera Trap Reports\n* Getting Event Types\n* Getting Events\n* Getting Observations\n* Getting Subject Groups\n* Getting Feature groups\n* Getting Sources\n* Getting Source Assignments (aka SubjectSource resources)\n```\nfrom erclient import AsyncERClient\n\n# You can use it as an async context-managed client\nasync with AsyncERClient(service_root=\"https://sandbox.pamdas.org/api/v1.0\", username=\"\", password=\"\") as client:\n await self.er_client.post_sensor_observation(position)\n await client.post_report(report)\n await self.er_client.post_camera_trap_report(camera_trap_payload, file)\n ...\n \nasync with AsyncERClient(service_root=\"https://sandbox.pamdas.org/api/v1.0\", username=\"\", password=\"\") as client:\n async for observation in client.get_observations(start=\"2023-11-10T00:00:00-06:00\"):\n print(observation)\n ...\n\n# Or create an instance and close the client explicitly later\nclient = AsyncERClient(service_root=\"https://sandbox.pamdas.org/api/v1.0\", username=\"\", password=\"\")\nawait self.er_client.post_sensor_observation(position)\nawait client.post_report(report)\nawait self.er_client.post_camera_trap_report(camera_trap_payload, file)\n...\nawait client.close() # Close the session used to send requests to ER API\n```\n",
"bugtrack_url": null,
"license": "Apache-2.0",
"summary": "Client for EarthRanger API",
"version": "1.8.0",
"project_urls": {
"Homepage": "http://github.com/PADAS/er-client"
},
"split_keywords": [
"earthranger",
" api"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "c9f844c4c2fc4a56bfe6d409cfd804494ca1c54a51e5d73c5df41e04a97953b9",
"md5": "b1f64696eff015933428fad1e294064d",
"sha256": "377dd703ea43572015467ec3d8a3101074998c57d49b83b25de735bfab9a5e15"
},
"downloads": -1,
"filename": "earthranger_client-1.8.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "b1f64696eff015933428fad1e294064d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 22641,
"upload_time": "2025-09-03T22:45:32",
"upload_time_iso_8601": "2025-09-03T22:45:32.758824Z",
"url": "https://files.pythonhosted.org/packages/c9/f8/44c4c2fc4a56bfe6d409cfd804494ca1c54a51e5d73c5df41e04a97953b9/earthranger_client-1.8.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "75b9be19c113166182bb1f21fc00e1c736b8adfca6fdb16b176a5817e17c8518",
"md5": "b7004e8ff182d33f457e1a004d337160",
"sha256": "72435a43efd7ac6e107a2f60c7175d9d36c8f97c774c3264e134b590be84df7f"
},
"downloads": -1,
"filename": "earthranger_client-1.8.0.tar.gz",
"has_sig": false,
"md5_digest": "b7004e8ff182d33f457e1a004d337160",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 297957,
"upload_time": "2025-09-03T22:45:34",
"upload_time_iso_8601": "2025-09-03T22:45:34.072036Z",
"url": "https://files.pythonhosted.org/packages/75/b9/be19c113166182bb1f21fc00e1c736b8adfca6fdb16b176a5817e17c8518/earthranger_client-1.8.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-09-03 22:45:34",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "PADAS",
"github_project": "er-client",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "earthranger-client"
}