---
title: "DeliveryToken"
description: "DeliveryToken"
url: "https://www.contentstack.com/docs/developers/sdks/content-management-sdk/java/reference/deliverytoken"
product: "Contentstack"
doc_type: "guide"
audience:
  - developers
  - admins
version: "current"
last_updated: "2026-09-04"
---

# DeliveryToken

## DeliveryToken

Delivery tokens provide read-only access to the associated environments, while management tokens provide read-write access to the content of your stack. Use these tokens and the stack API key to make authorized API requests.

## delete

The "Delete delivery token" request deletes a specific delivery token.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
Call<ResponseBody> response = deliveryToken.delete().execute();
if (response.isSuccessful) {
    System.out.println("Response" + response);
}
```

## update

The "Update delivery token" request lets you update the details of a delivery token.

In the Request Body, you need to pass the updated details of the delivery token in JSON format. The details include the updated name, description, and/or the environment of the delivery token.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
Call<ResponseBody> response = deliveryToken.update(requestBody).execute();
if (response.isSuccessful) {
    System.out.println("Response" + response);
}
```

Thee body should be a JSON Object.

## create

The Create delivery token request creates a delivery token in the stack.

In the Request Body, you need to pass the details of the delivery token in JSON format. The details include the name, description, and environment of the delivery token.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
Call<ResponseBody> response = deliveryToken.create(requestBody).execute();
if (response.isSuccessful) {
    System.out.println("Response" + response);
}
```

The request body to create a delivery token.

## find

The "Get all delivery tokens" request returns the details of all the delivery tokens created in a stack.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
Call<ResponseBody> response = deliveryToken.find().execute();
if (response.isSuccessful) {
    System.out.println("Response" + response);
}
```

## fetch

The "Get a single delivery token" request returns the details of all the delivery tokens created in a stack.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
Call<ResponseBody> response = deliveryToken.fetch().execute();
if (response.isSuccessful) {
    System.out.println("Response" + response);
}
```

## addParam

Sets header for the request.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
deliveryToken.addParam("key", value);
```

Query parameter key for the request.

Query parameter value for the request.

## removeParam

Sets header for the request.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
deliveryToken.removeParam("key");
```

Remove query parameters of request by key.

## addHeader

Sets header for the request.

```
import contentstack;
Contentstack contentstack = new Contentstack.Builder().build();
DeliveryToken deliveryToken = contentstack.stack().deliveryToken();
deliveryToken.addHeader("key", value);
```

Header key for the request.

Header value for the request.

## DeliveryToken | Java Management SDK | Contentstack

DeliveryToken provides read-only access to environments for making authorized content delivery requests in the Java Management SDK.