diff --git a/docs/specs/protocol-reference.rst b/docs/specs/protocol-reference.rst --- a/docs/specs/protocol-reference.rst +++ b/docs/specs/protocol-reference.rst @@ -210,6 +210,7 @@ We also highly recommend their CodeMeta equivalent, and any other relevant metadata, but this is not enforced. +.. _metatadata-only-deposit Metadata-only deposit ===================== diff --git a/docs/user-manual.rst b/docs/user-manual.rst --- a/docs/user-manual.rst +++ b/docs/user-manual.rst @@ -64,6 +64,7 @@ $ sudo apt install jq +.. _prepare_deposit Prepare a deposit ----------------- @@ -150,6 +151,11 @@ 2. Add data to a deposit (in multiple requests if needed) 3. Finalize deposit (the status becomes ``deposited``) +* a metadata-only deposit: + + The user posts in one query an associated metadata file on a :ref:`SWHID + ` object. The deposit is directly marked with status + ``done``. Overall, a deposit can be a in series of steps as follow: @@ -274,7 +280,58 @@ } +Metadata-only deposit +^^^^^^^^^^^^^^^^^^^^^ + +This allows to deposit only metadata information on a :ref:`SWHID reference +`. Prepare a metadata file as described in the +:ref:`prepare deposit section ` + +Ensure this metadata file also declares a :ref:`SWHID reference +`: + +.. code:: xml + + + + + + + + + + + + + + + +For this, we then need to provide the following information: + +* arguments: ``--username 'name' --password 'pass'`` as credentials +* metadata file path (example: ``--metadata path/to/metadata.xml``) + +to the `swh deposit metadata-only` command. + + +Example: + +.. code:: console + (deposit) swh deposit metadata-only --username --password \ + --url https://deposit.staging.swh.network/1 \ + --metadata ../deposit-swh.metadata-only.xml \ + --format json | jq . + { + "deposit_id": "29", + "deposit_status": "done", + "deposit_date": "Dec. 15, 2020, 11:37 a.m." + } + +For details on the metadata-only deposit, see the +:ref:`metadata-only deposit protocol reference ` Multisteps deposit ^^^^^^^^^^^^^^^^^^