---
title: "Assign Doi"
method: POST
path: "/datacatalog/api/data-release/{id}/assign-doi"
tags: ["Data Release"]
---

# Assign Doi

`POST /datacatalog/api/data-release/{id}/assign-doi`

## Request

- Base URL: `https://data.usgs.gov` (the document declares no server; this is the origin it was published from)
- URL: `https://data.usgs.gov/datacatalog/api/data-release/{id}/assign-doi`
- Auth: OAuth 2
  - Authorization code: `https://auth.globus.org/v2/oauth2/authorize?scope=openid`
  - Token URL: `https://data.usgs.gov/datacatalog/api/auth/login`

Assigns a DOI to a data release.

If a existing DOI value is passed that DOI will be assigned 
to the data release.

If no DOI value is passed a DOI in AIS will be created and 
assigned to the data release.

:param id: The ID of the data release.  
:param data: The AssignDoiRequest JSON of the DOI to create.  
:param token: A valid bearer token for the user.

## Path parameters

- `id` string, required

## Request body

- AssignDoiRequest
  - `doi` string, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `404`: Not found
- `422`: Validation Error

---

[API](https://skmtc.dev/usgs/apis/usgs-science-data-catalog-api-documentation.md) - [All operations](https://skmtc.dev/usgs/apis/usgs-science-data-catalog-api-documentation/llms.txt) - [OpenAPI document](https://skmtc.dev/usgs/apis/usgs-science-data-catalog-api-documentation/revisions/f5f6a07ba13f?raw)
