GeorepositoryConfig

class geodetic_engine.georepository.GeorepositoryConfig[source]

Bases: object

How to reach and authenticate against a Georepository instance.

api_url

Base URL of the instance, without the /api suffix. Must be https, since client credentials are sent on every token request.

client_id

OAuth2 client identifier.

client_secret

OAuth2 client secret.

token_url

OAuth2 token endpoint. Defaults to {api_url}/auth/connect/token. It is a separate setting because the token endpoint is not described by the OpenAPI document and cannot be assumed to sit under the API host.

scope

Scope requested for the client credentials grant.

page_size

Results requested per page.

request_timeout

Per-request timeout in seconds.

include_deprecated

Ask the API to include deprecated objects.

endpoint(name)[source]

Return the absolute URL of a v1 collection endpoint.

Parameters:

name (str) – Endpoint name such as GeodeticCoordRefSystem.

Return type:

str

Returns:

Absolute URL, for example https://example.org/api/v1/GeodeticCoordRefSystem.

__init__(api_url, client_id, client_secret, token_url='', scope='GeoRepositoryAPI_Scope', page_size=500, request_timeout=60.0, include_deprecated=True)