The offline map packages an app may download, with checksums
const url = 'https://api.tareky.com/v1/offline/catalog';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.tareky.com/v1/offline/catalog \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Legacy key id (until its sunset)
Responses
Section titled “Responses”object
Operator switch. False: no download or update is offered (what is installed keeps working)
Shape of this answer and of the packages; a client ignores a version it does not know
Data version of every package below: packages of one version only work together
object
object
object
Package id: core (required: the country-wide map and routing backbone) or a governorate such as gov-baghdad
Installed with every other package: nothing works offline without it
object
[west, south, east, north]
Download size of all the package’s files
object
Absolute address of the file (public CDN; an unguessable path)
Lowercase hex SHA-256: a client installs nothing that does not match
Examplegenerated
{ "enabled": true, "formatVersion": 1, "version": "example", "createdAt": "example", "countries": [ { "code": "example", "name": { "ar": "example", "en": "example" }, "packages": [ { "id": "example", "required": true, "name": { "ar": "example", "en": "example" }, "bbox": [ 1 ], "bytes": 1, "files": [ { "name": "example", "url": "example", "bytes": 1, "sha256": "example" } ] } ] } ]}Rate limit or monthly quota exceeded; see Retry-After
object
object
Stable machine-readable code, e.g. quota_exceeded, no_route
For invalid_request: the validation issues
Examplegenerated
{ "error": { "code": "example", "message": "example", "status": 1, "details": "example", "docsUrl": "example" }, "requestId": "example"}default
Section titled “default”Any other error, in the /v1 error envelope
object
object
Stable machine-readable code, e.g. quota_exceeded, no_route
For invalid_request: the validation issues
Examplegenerated
{ "error": { "code": "example", "message": "example", "status": 1, "details": "example", "docsUrl": "example" }, "requestId": "example"}