Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added requirement for graph identification in resource PUT #365

Merged
merged 4 commits into from
Aug 29, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions docs/developing/reference/api.txt
Original file line number Diff line number Diff line change
Expand Up @@ -495,9 +495,15 @@ Resources
}
}

.. http:put:: /resources/{uuid:resouce instance id}
.. http:put:: /resources/{uuid: graph id}/{uuid:resource instance id}

updates a single resource instance
.. note::
Instead of identifying a graph by a UUID, one can also identify a graph by by a slug identifier.
To get or set the slug for the graph, navigate to the root node of the :ref:`Graph Designer`. A request using a slug identifier for a graph looks like:
``PUT /resources/{string: graph slug}/{uuid:resource instance id}``


Updates a single resource instance

:query format: {"json-ld", "arches-json"}
:query indent: number of spaces to indent json output
Expand All @@ -508,7 +514,7 @@ Resources

.. code-block:: none

curl -H "Authorization: Bearer {token}" -X PUT -d {data in json-ld format} http://localhost:8000/resources/{resource instance id}
curl -H "Authorization: Bearer {token}" -X PUT -d {data in json-ld format} http://localhost:8000/resources/{graph id}/{resource instance id}

curl -H "Authorization: Bearer zo41Q1IMgAW30xOroiCUxjv3yci8Os" -X PUT \
-d '{
Expand Down