put
https://api.jmapcloud.io/api/mcs/rest/v1/organizations//projects//layers//form
Assigns a form to a layer of a project. The form replaces the form already assigned to the layer, if any.
Required role: ORG_EDITOR, and the current user must have the MODIFY permission on the project.
Fields
| Field | Required | Description |
|---|---|---|
formId | Yes | The id of a form of the layer's data source. |
Response
result is the id of the assigned form.
When it fails
400 if formId is missing or empty, if the layer isn't a vector layer, or if the form isn't a form of the layer's data source in your organization.
Form assignment
Forms are created on a data source (POST .../datasources/{datasource}/forms). Assigning a form to a layer makes it the form used to edit the layer's features in the project. A layer has at most one form.
- Only vector layers (
VECTOR,OGC_API_FEATURES) can have a form. - The form must be a form of the layer's data source, owned by your organization. The forms of a data source shared by another organization can't be assigned.
- The id of the assigned form is also the
formIdof the layer (GET .../layers/{layer}). - Deleting the form removes the assignment: the layer then has no form. Copying a layer (
"action": "clone") copies its form. - A referenced layer has its own form: it doesn't use the form of its source layer.
Organization
organization must be the organization of the access token, and the project must belong to it; otherwise the request returns 404.
Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…