Resource Identifiers¶
dandi
commands and Python functions accept URLs and URL-like identifiers in
the following formats for identifying Dandisets, assets, and asset collections.
Text in [brackets] is optional. A server
field is a base API or GUI URL
for a DANDI Archive instance. If an optional version
field is omitted from
a URL, the given Dandiset’s most recent published version will be used if it
has one, and its draft version will be used otherwise.
https://identifiers.org/DANDI:dandiset-id[/version]
(case insensitive;version
cannot be “draft”) when it redirects to one of the other URL formatsDANDI:dandiset-id[/version]
(case insensitive) — Refers to a Dandiset on the main archive instance named “dandi”.parse_dandi_url()
converts this format to aDandisetURL
.Any
https://gui.dandiarchive.org/
orhttps://*dandiarchive-org.netlify.app/
URL which redirects to one of the other URL formatshttps://server[/api]/[#/]dandiset/dandiset-id[/version][/files]
— Refers to a Dandiset.parse_dandi_url()
converts this format to aDandisetURL
.https://server[/api]/[#/]dandiset/dandiset-id[/version]/files?location=path
If the
glob
/--path-type glob
option is in effect, the URL refers to a collection of assets whose paths match the glob patternpath
, andparse_dandi_url()
will convert the URL to anAssetGlobURL
.If the
glob
/--path-type glob
option is not in effect, the URL refers to an asset folder by path, andparse_dandi_url()
will convert the URL to anAssetFolderURL
.
https://server[/api]/dandisets/dandiset-id[/versions[/version]]
— Refers to a Dandiset.parse_dandi_url()
converts this format to aDandisetURL
.https://server[/api]/assets/asset-id[/download]
— Refers to a single asset by identifier.parse_dandi_url()
converts this format to aBaseAssetIDURL
.https://server[/api]/dandisets/dandiset-id/versions/version/assets/asset-id[/download]
— Refers to a single asset by identifier.parse_dandi_url()
converts this format to anAssetIDURL
.https://server[/api]/dandisets/dandiset-id/versions/version/assets/?path=path
— Refers to all assets in the given Dandiset whose paths begin with the prefixpath
.parse_dandi_url()
converts this format to anAssetPathPrefixURL
.https://server[/api]/dandisets/dandiset-id/versions/version/assets/?glob=path
— Refers to all assets in the given Dandiset whose paths match the glob patternpath
.parse_dandi_url()
converts this format to anAssetGlobURL
.dandi://instance-name/dandiset-id[@version]
(whereinstance-name
is the name of a registered Dandi Archive instance) — Refers to a Dandiset.parse_dandi_url()
converts this format to aDandisetURL
.dandi://instance-name/dandiset-id[@version]/path
(whereinstance-name
is the name of a registered Dandi Archive instance)If the
glob
/--path-type glob
option is in effect, the URL refers to a collection of assets whose paths match the glob patternpath
, andparse_dandi_url()
will convert the URL to anAssetGlobURL
.If the
glob
/--path-type glob
option is not in effect andpath
ends with a trailing slash, the URL refers to an asset folder by path, andparse_dandi_url()
will convert the URL to anAssetFolderURL
.If the
glob
/--path-type glob
option is not in effect andpath
does not end with a trailing slash, the URL refers to a single asset by path, andparse_dandi_url()
will convert the URL to anAssetItemURL
.
Any other HTTPS URL that redirects to one of the above