> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/dsx-air/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/dsx-air/_mcp/server.

# Cancel a pending publish or visibility request

PATCH https://api.dsx-air.nvidia.com/api/v3/images/{id}/cancel-publish-access-record/

Cancels a gated community-manager queue entry for this image. Clears ``PENDING``, ``PENDING_ELEVATION``, ``PENDING_RESTRICTION``, ``PENDING_UNPUBLISH``, or ``PENDING_ALLOWLIST`` on the publish access record and restores matching ``upload_status`` (e.g. ``PENDING_PUBLISH`` or ``PENDING_UNPUBLISH`` → ``COMPLETE``). Same organization rules as the corresponding ``request-*`` routes. Returns **400** when nothing is pending or the image is in ``PUBLISHING`` / ``UNPUBLISHING``.

**Required scopes (any one):**

- `air:image_write` (roles: `air_image_publisher`, `air_image_uploader`)
- `air:image_publish` (roles: `air_image_publisher`)

Reference: https://docs.nvidia.com/dsx-air/api-reference/images/api-v-3-images-cancel-publish-access-record-partial-update

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `id` (string, required) — A UUID string identifying this image.

## Response

### 200

- `id` (string, required)
- `name` (string, required) — The `name` of the image. This must be unique with the `version`.
- `version` (string, required) — The `version` of the image. This must be unique with the `name`.
- `created` (datetime, required)
- `creator` (string, required, nullable) — The email of the user who created the image.
- `modified` (datetime, required)
- `default_username` (string, required) — The default username for authenticating with the operating system.
- `default_password` (string, required) — The default password for authenticating with the operating system.
- `published` (boolean, required) — Whether the image is published.
- `publicly_published` (boolean, required) — Whether the image is published to all users (public) vs restricted to an allow-list. Always `false` for unpublished images.
- `publish_access_record_id` (string, required, nullable) — The id of the image publish access record. Returned only to the owning organization, Air admins, and SREs; null otherwise.
- `upload_status` (enum, required) — The upload status of the image file. * `READY` - Ready * `UPLOADING` - Uploading * `VALIDATING` - Validating * `COMPLETE` - Complete * `PUBLISHING` - Publishing * `UNPUBLISHING` - Unpublishing * `COPYING_FROM_IMAGE_SHARE` - Copying from image share * `PENDING_PUBLISH` - Pending Publish * `PENDING_UNPUBLISH` - Pending Unpublish
  - Allowed values: `READY`, `UPLOADING`, `VALIDATING`, `COMPLETE`, `PUBLISHING`, `UNPUBLISHING`, `COPYING_FROM_IMAGE_SHARE`, `PENDING_PUBLISH`, `PENDING_UNPUBLISH`
- `last_uploaded_at` (datetime, required, nullable) — The date and time the image was last uploaded.
- `size` (integer, required) — The size of the image file in bytes.
- `hash` (string, required) — The hash of the image file. This is used to check if the content of the image has changed.
- `is_owned_by_client` (boolean, required) — If the image is owned by the client. When true, the client can share/publish/unpublish the image.
- `mountpoint` (string, optional, nullable) — Partition that hosts the operating system root file system.
- `minimum_resources` (object, optional) — The minimum resources required to run the image.
  - `cpu` (integer, required) — The minimum number of CPU cores required to run the image.
  - `memory` (integer, required) — The minimum amount of memory required to run the image.
  - `storage` (integer, required) — The minimum amount of storage required to run the image.
- `includes_air_agent` (boolean, optional, default: false) — Whether the image includes the Air Agent service.
- `cpu_arch` (enum, optional, default: x86) — The CPU architecture of the image. * `x86` - x86 * `ARM` - ARM
  - Allowed values: `x86`, `ARM`
- `emulation_type` (list of string, optional) — The types of emulation the image supports.
- `emulation_version` (string, optional) — The version of the emulation the image supports.
- `provider` (enum, optional, default: VM) — The provider of the image. * `VM` - VM * `CONTAINER` - CONTAINER
  - Allowed values: `VM`, `CONTAINER`
- `notes` (string, optional) — Notes about the image.
- `release_notes` (string, optional) — Release notes for the image.
- `user_manual` (string, optional) — User manual for the image.

## Errors

### 400 Bad Request Error

- `detail` (string, required) — Description of an error.
- `request_id` (string, required, nullable) — ID assigned to the request which encountered the error. Should be provided when opening a support case.
- `type` (enum, required) — Specific type of a 400 error. * `PROTECTED` - Instance may not be deleted as it is being referenced by other instances. * `VALIDATION` - Validation errors encountered during payload processing.
  - Allowed values: `PROTECTED`, `VALIDATION`
- `protected_instances` (list of object, optional) — Instances which bar the current instance from being deleted. Only defined when `type` is set to `PROTECTED`.
  - `id` (string, required) — ID of the instance.
  - `type` (string, required) — Type of the instance.
- `validation_errors` (map from string to list of object or object or map from string to any or list of object, optional) — Validation errors encountered during payload processing. Only defined when `type` is set to `VALIDATION`.

### 403 Forbidden Error

- `detail` (string, required) — Description of an error.
- `request_id` (string, required, nullable) — ID assigned to the request which encountered the error. Should be provided when opening a support case.

### 404 Not Found Error

- `request_id` (string, required, nullable) — ID assigned to the request which encountered the error. Should be provided when opening a support case.
- `detail` (string, optional, default: No object matches the given query.) — Description of an error.

### 500 Internal Server Error

- `request_id` (string, required, nullable) — ID assigned to the request which encountered the error. Should be provided when opening a support case.
- `code` (string, required) — Error code which identifies the error. Should be provided when opening a support case.
- `detail` (string, optional, default: An unexpected error has occurred. Please contact NVIDIA Air support for further assistance.) — Description of an error.

## Examples

**Response**

```json
{
  "id": "string",
  "name": "string",
  "version": "string",
  "created": "2024-01-15T09:30:00Z",
  "creator": "string",
  "modified": "2024-01-15T09:30:00Z",
  "default_username": "string",
  "default_password": "string",
  "published": true,
  "publicly_published": true,
  "publish_access_record_id": "string",
  "upload_status": "READY",
  "last_uploaded_at": "2024-01-15T09:30:00Z",
  "size": 1,
  "hash": "string",
  "is_owned_by_client": true,
  "mountpoint": "string",
  "minimum_resources": {
    "cpu": 1,
    "memory": 1,
    "storage": 1
  },
  "includes_air_agent": false,
  "cpu_arch": "x86",
  "emulation_type": [
    "string"
  ],
  "emulation_version": "string",
  "provider": "VM",
  "notes": "string",
  "release_notes": "string",
  "user_manual": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/"

headers = {"Authorization": "Bearer <token>"}

response = requests.patch(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/';
const options = {method: 'PATCH', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/"

	req, _ := http.NewRequest("PATCH", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.patch("https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('PATCH', 'https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "Bearer <token>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["Authorization": "Bearer <token>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.dsx-air.nvidia.com/api/v3/images/id/cancel-publish-access-record/")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```