SmartGare
API referenceEndpoints

Load an edition of an official list of places

Takes one whole edition of a source's list, or nothing when any of it is wrong. A place keeps its identifier across editions; one the edition no longer lists is retired and stays readable; the same edition loaded twice changes no place. Answers what it added, changed, retired and left as it was, and records who loaded it. **Required permission:** `referential.topographic-place:write`

POST/referential/v1/topographic-place-lists

Takes one whole edition of a source's list, or nothing when any of it is wrong. A place keeps its identifier across editions; one the edition no longer lists is retired and stays readable; the same edition loaded twice changes no place. Answers what it added, changed, retired and left as it was, and records who loaded it.

Required permission: referential.topographic-place:write

AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

body*LoadTopographicPlaceListRequest

Response Body

*/*

curl -X POST "https://example.com/referential/v1/topographic-place-lists" \  -H "Content-Type: application/json" \  -d '{    "kinds": [      {        "code": "string",        "level": 0,        "name": "string"      }    ],    "places": [      {        "code": "string",        "kind_code": "string",        "name": "string"      }    ],    "source": {      "code": "string",      "name": "string",      "publisher": "string",      "received_on": "2019-08-24",      "status": "string"    }  }'
{  "added": 0,  "changed": 0,  "edition": "string",  "loaded_at": "2019-08-24T14:15:22Z",  "loaded_by": "string",  "retired": 0,  "source": "string",  "unchanged": 0}