> For the complete documentation index, see [llms.txt](https://docs.stackai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.stackai.com/integrations/catalog/confluence.md).

# Confluence

Connect to Confluence for document management and collaboration.

* Knowledge base source

### Connectors

Choose the connector that matches your authentication method. The options below use the names shown in StackAI.

| Connector  | Authentication |
| ---------- | -------------- |
| Confluence | OAuth sign-in  |

#### Confluence

Connect to Atlassian Confluence using OAuth2. Enterprise knowledge management and collaboration.

**Set up in Confluence**

1. Use a Confluence account with access to the records and operations that your workflow needs.
2. If your organization restricts application access or user consent, have its administrator approve the connection before you sign in.

**Set up in StackAI**

1. Open **Settings → Connections**, add a connection, and select **Confluence**.
2. Select **Connect**, sign in to the provider account, and review the requested access. Complete authorization to return to StackAI.
3. Complete the fields marked for use after sign-in, such as the business or account selection.
4. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

**Connection fields**

| StackAI field   | Required                 | What to enter                                                  |
| --------------- | ------------------------ | -------------------------------------------------------------- |
| Confluence Site | Optional / as applicable | The Atlassian Cloud site to use. Select this after signing in. |

**Provider documentation:** [Setup reference](https://developer.atlassian.com/cloud/confluence/oauth-2-3lo-apps/).

#### Verify the connection

Check that the connection is healthy. Then run a read operation against a resource the connected account can access. A successful connection check confirms authentication; it does not guarantee permission for every action.

If access is denied, check the credential or OAuth permissions, the selected account or environment, and access to the specific resource. Update expired credentials or reconnect after permissions change.

### Use an action

1. Add the required **Confluence** action to the workflow.
2. Select a connection when the action requests one.
3. Complete the required fields. Use the reference picker when a value comes from another workflow step.
4. Run the workflow and inspect the action’s output. Check the result before using it in a later step.

### Actions

#### Get Attachments

Returns all attachments

**Inputs**

| Field     | Type          | Required | Description                                                                                                                                                                                                      |
| --------- | ------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Sort      | string        | No       | The sort fields for attachments. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Cursor    | string        | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                       |
| Status    | string\_array | No       | Filter the results to attachments based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Mediatype | string        | No       | Filters on the mediaType of attachments. Only one may be specified.                                                                                                                                              |
| Filename  | string        | No       | Filters on the file-name of attachments. Only one may be specified.                                                                                                                                              |
| Limit     | integer       | No       | Maximum number of attachments per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 50. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Attachments For Blog Post

Returns the attachments of specific blog post.

**Inputs**

| Field     | Type            | Required | Description                                                                                                                                                                                                      |
| --------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Blog Post | select (string) | Yes      | The blog post whose attachments should be returned. Options load from the selected connection.                                                                                                                   |
| Sort      | string          | No       | The sort fields for attachments. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Cursor    | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                       |
| Status    | string\_array   | No       | Filter the results to attachments based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Mediatype | string          | No       | Filters on the mediaType of attachments. Only one may be specified.                                                                                                                                              |
| Filename  | string          | No       | Filters on the file-name of attachments. Only one may be specified.                                                                                                                                              |
| Limit     | integer         | No       | Maximum number of attachments per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 50. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Attachments For Custom Content

Returns the attachments of specific custom content.

**Inputs**

| Field          | Type            | Required | Description                                                                                                                                                                                                      |
| -------------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Custom Content | select (string) | Yes      | The custom content whose attachments should be returned. Options load from the selected connection.                                                                                                              |
| Sort           | string          | No       | The sort fields for attachments. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Cursor         | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                       |
| Status         | string\_array   | No       | Filter the results to attachments based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Mediatype      | string          | No       | Filters on the mediaType of attachments. Only one may be specified.                                                                                                                                              |
| Filename       | string          | No       | Filters on the file-name of attachments. Only one may be specified.                                                                                                                                              |
| Limit          | integer         | No       | Maximum number of attachments per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 50. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Custom Content By Type In Page

Returns all custom content for a given type within a given page.

**Inputs**

| Field       | Type            | Required | Description                                                                                                                                                                                                               |
| ----------- | --------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Page        | select (string) | Yes      | The page for which custom content should be returned. Options load from the selected connection.                                                                                                                          |
| Type        | string          | Yes      | The type of custom content being requested.                                                                                                                                                                               |
| Sort        | string          | No       | The sort fields for custom content. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                         |
| Cursor      | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                                |
| Limit       | integer         | No       | Maximum number of custom content items per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 25. |
| Body-Format | string          | No       | The formats a custom content body can be represented as. A subset of BodyRepresentation.                                                                                                                                  |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Custom Content By Type In Space

Returns all custom content for a given type within a given space.

**Inputs**

| Field       | Type            | Required | Description                                                                                                                                                                                                               |
| ----------- | --------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Space       | select (string) | Yes      | The space for which custom content should be returned. Options load from the selected connection.                                                                                                                         |
| Type        | string          | Yes      | The type of custom content being requested.                                                                                                                                                                               |
| Cursor      | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                                |
| Limit       | integer         | No       | Maximum number of custom content items per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 25. |
| Body-Format | string          | No       | The formats a custom content body can be represented as. A subset of BodyRepresentation.                                                                                                                                  |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Pages For Label

Returns the pages of specified label.

**Inputs**

| Field       | Type            | Required | Description                                                                                                                                                                                                |
| ----------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Label       | select (string) | Yes      | The label whose pages should be returned. Options load from the selected connection.                                                                                                                       |
| Space-Id    | string\_array   | No       | Filter the results based on space ids. Multiple space ids can be specified as a comma-separated list.                                                                                                      |
| Body-Format | string          | No       | The primary formats a body can be represented as. A subset of BodyRepresentation. These formats are the only allowed formats in certain use cases.                                                         |
| Sort        | string          | No       | The sort fields for pages. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Cursor      | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                 |
| Limit       | integer         | No       | Maximum number of pages per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 25. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Attachments For Page

Returns the attachments of specific page.

**Inputs**

| Field     | Type            | Required | Description                                                                                                                                                                                                      |
| --------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Page      | select (string) | Yes      | The page whose attachments should be returned. Options load from the selected connection.                                                                                                                        |
| Sort      | string          | No       | The sort fields for attachments. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Cursor    | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                       |
| Status    | string\_array   | No       | Filter the results to attachments based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Mediatype | string          | No       | Filters on the mediaType of attachments. Only one may be specified.                                                                                                                                              |
| Filename  | string          | No       | Filters on the file-name of attachments. Only one may be specified.                                                                                                                                              |
| Limit     | integer         | No       | Maximum number of attachments per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 50. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Page By Id

Returns a specific page.

**Inputs**

| Field                                    | Type            | Required | Description                                                                                                                                        |
| ---------------------------------------- | --------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| Page                                     | select (string) | Yes      | The page to be returned. Options load from the selected connection.                                                                                |
| Body-Format                              | string          | No       | The primary formats a body can be represented as. A subset of BodyRepresentation. These formats are the only allowed formats in certain use cases. |
| Get-Draft                                | boolean         | No       | Retrieve the draft version of this page. Default: false.                                                                                           |
| Status                                   | string\_array   | No       | Filter the page being retrieved by its status.                                                                                                     |
| Version                                  | integer         | No       | Allows you to retrieve a previously published version. Specify the previous version's number to retrieve its details.                              |
| Include-Labels                           | boolean         | No       | Includes labels associated with this page in the response. Default: false.                                                                         |
| Include-Properties                       | boolean         | No       | Includes content properties associated with this page in the response. Default: false.                                                             |
| Include-Operations                       | boolean         | No       | Includes operations associated with this page in the response, as defined in the `Operation` object. Default: false.                               |
| Include-Likes                            | boolean         | No       | Includes likes associated with this page in the response. Default: false.                                                                          |
| Include-Versions                         | boolean         | No       | Includes versions associated with this page in the response. Default: false.                                                                       |
| Include-Version                          | boolean         | No       | Includes the current version associated with this page in the response. Default: true.                                                             |
| Include-Favorited-By-Current-User-Status | boolean         | No       | Includes whether this page has been favorited by the current user. Default: false.                                                                 |
| Include-Webresources                     | boolean         | No       | Includes web resources that can be used to render page content on a client. Default: false.                                                        |
| Include-Collaborators                    | boolean         | No       | Includes collaborators on the page. Default: false.                                                                                                |
| Include-Direct-Children                  | boolean         | No       | Includes direct children of the page, as defined in the `ChildrenResponse` object. Default: false.                                                 |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Pages

Returns all pages.

**Inputs**

| Field       | Type          | Required | Description                                                                                                                                                                                                |
| ----------- | ------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Id          | string\_array | No       | Filter the results based on page ids. Multiple page ids can be specified as a comma-separated list.                                                                                                        |
| Space-Id    | string\_array | No       | Filter the results based on space ids. Multiple space ids can be specified as a comma-separated list.                                                                                                      |
| Sort        | string        | No       | The sort fields for pages. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Status      | string\_array | No       | Filter the results to pages based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Title       | string        | No       | Filter the results to pages based on their title.                                                                                                                                                          |
| Body-Format | string        | No       | The primary formats a body can be represented as. A subset of BodyRepresentation. These formats are the only allowed formats in certain use cases.                                                         |
| Subtype     | string        | No       | Filter the results to pages based on their subtype.                                                                                                                                                        |
| Cursor      | string        | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                 |
| Limit       | integer       | No       | Maximum number of pages per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 25. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Get Pages In Space

Returns all pages in a space.

**Inputs**

| Field       | Type            | Required | Description                                                                                                                                                                                                |
| ----------- | --------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Space       | select (string) | Yes      | The space whose pages should be returned. Options load from the selected connection.                                                                                                                       |
| Depth       | string          | No       | Filter the results to pages at the root level of the space or to all pages in the space. Default: all.                                                                                                     |
| Sort        | string          | No       | The sort fields for pages. The default sort direction is ascending. To sort in descending order, append a `-` character before the sort field. For example, `fieldName` or `-fieldName`.                   |
| Status      | string\_array   | No       | Filter the results to pages based on their status. By default, `current` and `archived` are used.                                                                                                          |
| Title       | string          | No       | Filter the results to pages based on their title.                                                                                                                                                          |
| Body-Format | string          | No       | The primary formats a body can be represented as. A subset of BodyRepresentation. These formats are the only allowed formats in certain use cases.                                                         |
| Cursor      | string          | No       | Used for pagination, this opaque cursor will be returned in the `next` URL in the `Link` response header. Use the relative URL in the `Link` header to retrieve the `next` set of results.                 |
| Limit       | integer         | No       | Maximum number of pages per result to return. If more results exist, use the `Link` header to retrieve a relative URL that will return the next set of results. Minimum: 1.0. Maximum: 250.0. Default: 25. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Update Page

Update a page by id.

**Inputs**

| Field        | Type            | Required | Description                                                        |
| ------------ | --------------- | -------- | ------------------------------------------------------------------ |
| Page         | select (string) | Yes      | The page to be updated. Options load from the selected connection. |
| Request Body | object          | No       |                                                                    |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Delete Page

Delete a page by id.

**Inputs**

| Field | Type            | Required | Description                                                        |
| ----- | --------------- | -------- | ------------------------------------------------------------------ |
| Page  | select (string) | Yes      | The page to be deleted. Options load from the selected connection. |
| Purge | boolean         | No       | If attempting to purge the page. Default: false.                   |
| Draft | boolean         | No       | If attempting to delete a page that is a draft. Default: false.    |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

#### Create Page

Creates a page in the space.

**Inputs**

| Field        | Type            | Required | Description                                                                                                                                 |
| ------------ | --------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
| Embedded     | boolean         | No       | Tag the content as embedded and content will be created in NCS. Default: false.                                                             |
| Private      | boolean         | No       | The page will be private. Only the user who creates this page will have permission to view and edit one. Default: false.                    |
| Root-Level   | boolean         | No       | The page will be created at the root level of the space (outside the space homepage tree). Default: false.                                  |
| Request Body | object          | No       |                                                                                                                                             |
| Space        | select (string) | Yes      | The space this page will be created in. Options load from the selected connection.                                                          |
| Parent Page  | select (string) | No       | The parent page. Leave empty to use the space homepage (or set Root Level to create at the top). Options load from the selected connection. |

**Outputs**

| Field       | Type    | Description                  |
| ----------- | ------- | ---------------------------- |
| Status Code | integer | Status code of the response. |
| Headers     | dict    | Headers of the response.     |
| Body        | object  | Body of the response.        |

### Important behavior

If an operation is denied, check the connection’s granted permissions and the account’s access in the provider. Reauthorize the connection when it needs additional permissions.

Actions that create, update, send, or delete data can change the connected service. Review their inputs before running them. A retry can repeat an operation; consider this when configuring retries for actions that change data.

The catalog lists the fields and capabilities available in the supplied provider definition. Availability can also depend on your deployment and organization’s Feature Access settings.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.stackai.com/integrations/catalog/confluence.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
