View the documentation here: https://developers.woosmap.com/api-reference/
An OpenAPI specification for Woosmap Platform.
| API | Status |
|---|---|
| Geolocation | Complete |
| Stores | Complete |
| Localities | Complete |
| Distance | Complete |
| Transit | Complete |
| Indoor | Complete |
The repository makes use of Bazel to generate outputs from the specification and sample requests.
The APIs that publish their own spec at https://api.woosmap.com/<name>/openapi.json are vendored in upstream/ and
merged into dist/merged-woosmap-openapi3.json. A weekly workflow refreshes them and opens a PR when they change.
npm run sync:upstream does the same refresh locally.
To be able to generate responses, you'll need a woosmap public key and woosmap private key.
Once generated, it's convenient to add these environment variables in the file .bazelrc.user at the root of the
repository like this:
run --action_env WOOSMAP_PUBLIC_API_KEY=woos-xxxxxxxx
run --action_env WOOSMAP_PRIVATE_API_KEY=da4e8e73-xxxxx-xxxxThen you'll be able to execute following command.
-
npm i -
npm run buildThis generates the following outputs in the dist folder:
- YAML file containing OpenAPI3 specification
- JSON file containing OpenAPI3 specification
- Structure Markdown documents for specification objects
- Code snippets in multiple languages for sample requests
Note: The
dist/folder is included in this repo and should be updated with all changes.Note: If a documentation item is not generated, be sure it is included in the appropriate index.yml file.
-
npm run responses(optional)Note: This is an optional step requiring an API key. Set the
WOOSMAP_PUBLIC_API_KEYandWOOSMAP_PRIVATE_API_KEYenvironmental variable before running.Warning: Data attached to the
WOOSMAP_PRIVATE_API_KEYwill be deleted. Use an empty test project for this.Note: This step only needs to run when the generation code or sample requests have been updated.
Note: A single response can be updated similar to
npm run responses -- --only woosmap_http_address_details. -
npm run samples(optional)Note: Generates snippets from requests to be integrated as xCodeSamples in path schemas.
-
npm run testValidate the OpenAPI Schema