Skip to content

Commit 1166f1a

Browse files
authored
Docs for individual submission or entity geojson endpoints (#1674)
1 parent d14ce44 commit 1166f1a

File tree

1 file changed

+163
-0
lines changed

1 file changed

+163
-0
lines changed

docs/api.yaml

Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6060,6 +6060,58 @@ paths:
60606060
<name>Alice</name>
60616061
<age>32</age>
60626062
</data>
6063+
/v1/projects/{projectId}/forms/{xmlFormId}/submissions/{instanceId}.geojson:
6064+
get:
6065+
tags:
6066+
- Submissions
6067+
summary: Retrieving Submission GeoJSON
6068+
description: To retrieve the GeoJSON representation of the `Submission`, just append `.geojson` to
6069+
the end of the request URL.
6070+
operationId: Retrieving Submission GeoJSON
6071+
parameters:
6072+
- name: projectId
6073+
in: path
6074+
description: The numeric ID of the Project
6075+
required: true
6076+
schema:
6077+
type: number
6078+
example: "16"
6079+
- name: xmlFormId
6080+
in: path
6081+
description: The `xmlFormId` of the Form being referenced.
6082+
required: true
6083+
schema:
6084+
type: string
6085+
example: simple
6086+
- name: instanceId
6087+
in: path
6088+
description: The `instanceId` of the Submission being referenced.
6089+
required: true
6090+
schema:
6091+
type: string
6092+
example: uuid:85cb9aff-005e-4edd-9739-dc9c1a829c44
6093+
responses:
6094+
"200":
6095+
description: OK
6096+
content:
6097+
application/json:
6098+
example: |
6099+
{
6100+
"type": "FeatureCollection",
6101+
"features": [
6102+
{
6103+
"type": "Feature",
6104+
"id": "uuid:85cb9aff-005e-4edd-9739-dc9c1a829c44",
6105+
"geometry": {
6106+
"type": "Point",
6107+
"coordinates": [4.7871262893819555, 52.24107555748181, 0]
6108+
},
6109+
"properties": {
6110+
"fieldpath": "/singular/input_geopoint"
6111+
}
6112+
}
6113+
]
6114+
}
60636115
/v1/projects/{projectId}/forms/{xmlFormId}/submissions/{instanceId}/edit:
60646116
get:
60656117
tags:
@@ -7110,6 +7162,65 @@ paths:
71107162
<name>Alice</name>
71117163
<age>32</age>
71127164
</data>
7165+
/v1/projects/{projectId}/forms/{xmlFormId}/submissions/{instanceId}/versions/{versionId}.geojson:
7166+
get:
7167+
tags:
7168+
- Submission Versions
7169+
summary: Getting Version GeoJSON
7170+
description: Returns the GeoJSON of a particular version of the submission.
7171+
operationId: Getting Version GeoJSON
7172+
parameters:
7173+
- name: projectId
7174+
in: path
7175+
description: The numeric ID of the Project
7176+
required: true
7177+
schema:
7178+
type: number
7179+
example: "16"
7180+
- name: xmlFormId
7181+
in: path
7182+
description: The `xmlFormId` of the Form being referenced.
7183+
required: true
7184+
schema:
7185+
type: string
7186+
example: simple
7187+
- name: instanceId
7188+
in: path
7189+
description: The `instanceId` of the Submission being referenced.
7190+
required: true
7191+
schema:
7192+
type: string
7193+
example: uuid:85cb9aff-005e-4edd-9739-dc9c1a829c44
7194+
- name: versionId
7195+
in: path
7196+
description: The `instanceId` of the particular version of this submission
7197+
in question.
7198+
required: true
7199+
schema:
7200+
type: string
7201+
example: uuid:b1628661-65ed-4cab-8e30-19c17fef2de0
7202+
responses:
7203+
"200":
7204+
description: OK
7205+
content:
7206+
application/xml:
7207+
example: |
7208+
{
7209+
"type": "FeatureCollection",
7210+
"features": [
7211+
{
7212+
"type": "Feature",
7213+
"id": "uuid:b1628661-65ed-4cab-8e30-19c17fef2de0",
7214+
"geometry": {
7215+
"type": "Point",
7216+
"coordinates": [4.7871262893819555, 52.24107555748181, 0]
7217+
},
7218+
"properties": {
7219+
"fieldpath": "/singular/input_geopoint"
7220+
}
7221+
}
7222+
]
7223+
}
71137224
/v1/projects/{projectId}/forms/{xmlFormId}/submissions/{instanceId}/versions/{versionId}/attachments:
71147225
get:
71157226
tags:
@@ -9098,6 +9209,58 @@ paths:
90989209
action: entity.create
90999210
acteeId: 85cb9aff-005e-4edd-9739-dc9c1a829c44
91009211
loggedAt: 2018-04-18T23:19:14.802Z
9212+
/v1/projects/{projectId}/datasets/{name}/entities/{uuid}/geojson:
9213+
get:
9214+
tags:
9215+
- Entity Management
9216+
summary: Entity GeoJSON representation
9217+
description: Returns the GeoJSON representation of an Entity's `geometry` attribute, if available.
9218+
operationId: Entity GeoJSON representation
9219+
parameters:
9220+
- name: projectId
9221+
in: path
9222+
description: The numeric ID of the Project
9223+
required: true
9224+
schema:
9225+
type: number
9226+
example: "16"
9227+
- name: name
9228+
in: path
9229+
description: Name of the Dataset
9230+
required: true
9231+
schema:
9232+
type: string
9233+
example: people
9234+
- name: uuid
9235+
in: path
9236+
description: UUID of the Entity
9237+
required: true
9238+
schema:
9239+
type: string
9240+
example: 54a405a0-53ce-4748-9788-d23a30cc3afa
9241+
responses:
9242+
"200":
9243+
description: OK
9244+
content:
9245+
application/json:
9246+
schema:
9247+
description: GeoJSON FeatureCollection, with one Feature.
9248+
type: object
9249+
example: |
9250+
{
9251+
"type": "FeatureCollection",
9252+
"features": [
9253+
{
9254+
"type": "Feature",
9255+
"id": "54a405a0-53ce-4748-9788-d23a30cc3afa",
9256+
"properties": null,
9257+
"geometry": {
9258+
"type": "Point",
9259+
"coordinates": [1.087337169764714, 40.007726575882074, 44.93365478515625]
9260+
}
9261+
}
9262+
]
9263+
}
91019264
/v1/projects/{projectId}/datasets/{name}/entities/bulk-delete:
91029265
post:
91039266
tags:

0 commit comments

Comments
 (0)