---
title: godo.ActionGateway.Connections.Delete()
description: Delete revokes and deletes a connection.
product: Reference
url: https://docs.digitalocean.com/reference/godo/reference/action-gateway-connections/action-gateway-connections-delete/
last_updated: "2026-11-05"
---

> **For AI agents:** The documentation index is at [https://docs.digitalocean.com/llms.txt](https://docs.digitalocean.com/llms.txt). Markdown versions of pages use the same URL with `index.html.md` in place of the HTML page (for example, append `index.html.md` to the directory path instead of opening the HTML document).

# godo.ActionGateway.Connections.Delete()

Generated on 5 Nov 2026 from godo version [`v1.236.0`](https://github.com/digitalocean/godo/releases/tag/v1.236.0)

## Usage

```go
client.ActionGateway.Connections.Delete(ctx context.Context, id string) (*godo.ActionGatewayConnectionResponse, *godo.Response, error)
```

## Description

`Delete` revokes and deletes a connection.

This method sends a DELETE request to [`/v2/action-gateway/connections/{}`](https://docs.digitalocean.com/reference/api/reference/action-gateway/index.html.md#connections_delete).

## Parameters

`id` string required

## Returns

\*godo.ActionGatewayConnectionResponse

\*godo.Response

The HTTP response, with pagination `Links`, `Meta`, and `Rate` limit information.

error

Non-nil when the request fails. API errors are returned as `*godo.ErrorResponse`.

### Fields of `godo.ActionGatewayConnectionResponse`

`ActionGatewayConnectionResponse` contains one connection and any pending authorization.

`Connection` \*godo.ActionGatewayConnection

JSON key: `connection`

`Authorization` \*godo.ActionGatewayConnectionAuthorization

JSON key: `authorization`

## Request Sample

## Show Request Sample

```go
package main

import (
	"context"
	"fmt"
	"log"
	"os"

	"github.com/digitalocean/godo"
)

func main() {
	client := godo.NewFromToken(os.Getenv("DIGITALOCEAN_TOKEN"))
	ctx := context.TODO()

	result, _, err := client.ActionGateway.Connections.Delete(ctx, "<your-id>")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", result)
}
```

## Response Example

## Show Response Example

```json
{
  "connection": {
    "id": "39f9f768-a7f9-4c91-9557-3328c53dd054",
    "provider": "jira",
    "provider_display_name": "Jira",
    "user_id": "alice",
    "status": "revoked",
    "created_at": "2026-07-14T00:50:00Z",
    "updated_at": "2026-08-01T09:00:00Z",
    "revoked_at": "2026-08-01T09:00:00Z",
    "connection_parameters": {
      "site_url": "https://example.atlassian.net"
    },
    "credential_kind": "digitalocean_oauth",
    "credential_id": "",
    "network": null,
    "scopes": [
      "write:jira-work"
    ],
    "granted_at": "2026-07-14T00:52:10Z",
    "oauth": {
      "scopes": [
        "write:jira-work"
      ],
      "granted_at": "2026-07-14T00:52:10Z"
    }
  }
}
```

## More Information

See [`DELETE /v2/action-gateway/connections/{}`](https://docs.digitalocean.com/reference/api/reference/action-gateway/index.html.md#connections_delete) in the API reference for additional detail on responses, headers, parameters, and more.

See the [Go package documentation](https://pkg.go.dev/github.com/digitalocean/godo#ActionGatewayConnectionsService.Delete) for the source of this method.