openapi: 3.1.0 info: title: fw_api version: '1.0' servers: - url: 'https://api.resourcewatch.org' description: Production - url: 'https://gfw-staging.globalforestwatch.org' description: Staging - url: 'http://localhost:4400' description: Local paths: /v1/forest-watcher/area: parameters: [] get: summary: Get All User Areas operationId: get-user-areas description: Retrieve areas for the logged in user responses: '200': description: OK '401': $ref: '#/components/responses/Error' '404': $ref: '#/components/responses/Error' parameters: [] post: summary: Create User Area operationId: post-user-area responses: '200': description: OK '401': $ref: '#/components/responses/Error' description: Create a new area for the logged in user /v1/fw_api/healthcheck: get: summary: Healthcheck tags: [] responses: '200': $ref: '#/components/responses/Healthcheck' operationId: get-fw_api-healthcheck security: [] parameters: [] /v3/fw_api/healthcheck: get: summary: Healthcheck tags: [] responses: '200': $ref: '#/components/responses/Healthcheck' operationId: get-fw_api-healthcheck security: [] parameters: [] /v3/forest-watcher/area: get: summary: Your GET endpoint tags: [] responses: '200': description: OK content: application/json: schema: description: '' type: object x-examples: example-1: type: area id: 6233708756b0c7001bf95232 attributes: name: tests application: gfw geostore: geojson: crs: {} type: FeatureCollection features: [] hash: 507d44b65582536fe66f3b07ebf61048 provider: {} areaHa: 270746.1770155709 bbox: - 45.874121 - -19.815394 - 46.635037 - -19.180536 lock: false info: use: {} id: 507d44b65582536fe66f3b07ebf61048 userId: 62334dae880445001a46c494 createdAt: '2022-03-17T17:31:51.336Z' updatedAt: '2022-03-21T12:44:48.675Z' image: 'https://s3.amazonaws.com/forest-watcher-files/areas-staging/61327887-317a-4ce7-b17e-7eed159d507a.png' env: production datasets: - cache: true active: false _id: 6238734056b0c7001bf9523b slug: umd_as_it_happens name: GLAD startDate: '6' endDate: '20220321' - cache: true active: true _id: 6238734056b0c7001bf9523c slug: viirs name: VIIRS startDate: '1' endDate: '8' use: {} iso: {} coverage: - umd_as_it_happens reportTemplate: null properties: type: type: string minLength: 1 id: type: string minLength: 1 attributes: type: object required: - name - application - geostore - userId - createdAt - updatedAt - image - env - datasets - use - iso - coverage properties: name: type: string minLength: 1 application: type: string minLength: 1 geostore: type: object required: - geojson - hash - provider - areaHa - bbox - lock - info - id properties: geojson: type: object required: - crs - type - features properties: crs: type: object type: type: string minLength: 1 features: type: array items: type: object hash: type: string minLength: 1 provider: type: object areaHa: type: number bbox: type: array items: type: object lock: type: boolean info: type: object required: - use properties: use: type: object id: type: string minLength: 1 userId: type: string minLength: 1 createdAt: type: string minLength: 1 updatedAt: type: string minLength: 1 image: type: string minLength: 1 env: type: string minLength: 1 datasets: type: array uniqueItems: true minItems: 1 items: type: object properties: cache: type: boolean active: type: boolean _id: type: string minLength: 1 slug: type: string minLength: 1 name: type: string minLength: 1 startDate: type: string minLength: 1 endDate: type: string minLength: 1 required: - cache - active - _id - slug - name - startDate - endDate use: type: object iso: type: object coverage: type: array items: type: object reportTemplates: type: array items: type: object required: - type - id - attributes '401': $ref: '#/components/responses/Error' '404': $ref: '#/components/responses/Error' operationId: get-v3-forest-watcher-area description: Retrieve areas for the logged in user post: summary: '' operationId: post-v3-forest-watcher-area responses: '200': description: OK '401': $ref: '#/components/responses/Error' '403': $ref: '#/components/responses/Error' description: Create a new area for the logged in user '/v3/forest-watcher/area/{areaId}/template/{templateId}': parameters: - schema: type: string name: areaId in: path required: true - schema: type: string name: templateId in: path required: true post: summary: '' operationId: post-v3-forest-watcher-area-areaId-template-templateId responses: '200': description: OK '401': $ref: '#/components/responses/Error' '404': $ref: '#/components/responses/Error' description: Link a template to an area delete: summary: '' operationId: delete-v3-forest-watcher-area-areaId-template-templateId responses: '200': description: OK '401': description: Unauthorized '404': description: Not Found description: Remove a template from an area components: schemas: {} securitySchemes: Authorization: type: http scheme: bearer responses: Error: description: Error Response content: application/json: schema: description: '' type: object properties: errors: type: array uniqueItems: true minItems: 1 items: required: - status - detail properties: status: type: number detail: type: string minLength: 1 required: - errors examples: {} Healthcheck: description: Healthcheck response content: application/json: schema: type: object properties: uptime: type: number examples: {} examples: {} security: - Authorization: []