1.0.166 • Published 4 years ago

fetch-confluence v1.0.166

Weekly downloads
56
License
MIT
Repository
-
Last release
4 years ago

fetch-confluence

A simple and typed library, based on OpenAPI spec from developer.atlassian.com, for accessing product APIs.

TypeScript

Fetch Confluence - Documentation

Contents

Methods


The AuditApi object

createAuditRecord() - Create audit record

Creates a record in the audit log.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).createAuditRecord({
  AuditRecordCreate: { ... }
});
exportAuditRecords() - Export audit records

Exports audit records as a CSV file or ZIP file.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).exportAuditRecords({ ...args });
getAuditRecords() - Get audit records

Returns all records in the audit log, optionally for a certain date range. This contains information about events like space exports, group membership changes, app installations, etc. For more information, see Audit log in the Confluence administrator's guide.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).getAuditRecords({ ...args });
getAuditRecordsForTimePeriod() - Get audit records for time period

Returns records from the audit log, for a time period back from the current date. For example, you can use this method to get the last 3 months of records.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).getAuditRecordsForTimePeriod({ ...args });
getRetentionPeriod() - Get retention period

Returns the retention period for records in the audit log. The retention period is how long an audit record is kept for, from creation date until it is deleted.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).getRetentionPeriod({ ...args });
setRetentionPeriod() - Set retention period

Sets the retention period for records in the audit log. The retention period can be set to a maximum of 20 years.

Usage:

import { AuditApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new AuditApi(config).setRetentionPeriod({
  RetentionPeriod: { ... }
});

The ContentApi object

createContent() - Create content

Creates a new piece of content or publishes an existing draft.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).createContent({
  status: string
  ContentCreate: { ... }
});
deleteContent() - Delete content

Moves a piece of content to the space's trash or purges it from the trash, depending on the content's type and status:

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).deleteContent({ ...args });
getContent() - Get content

Returns all content in a Confluence instance.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).getContent({ ...args });
getContentById() - Get content by ID

Returns a single piece of content, like a page or a blog post.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).getContentById({ ...args });
getHistoryForContent() - Get history for content

Returns the most recent update for a piece of content.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).getHistoryForContent({ ...args });
getMacroBodyByMacroId() - Get macro body by macro ID

Returns the body of a macro in storage format, for the given macro ID. This includes information like the name of the macro, the body of the macro, and any macro parameters. This method is mainly used by Cloud apps.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).getMacroBodyByMacroId({ ...args });
searchContentByCQL() - Search content by CQL

Returns the list of content that matches a Confluence Query Language (CQL) query. For information on CQL, see: Advanced searching using CQL.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).searchContentByCQL({ ...args });
updateContent() - Update content

Updates a piece of content. Use this method to update the title or body of a piece of content, change the status, change the parent page, and more.

Usage:

import { ContentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentApi(config).updateContent({
  id: string
  status: string
  conflictPolicy: string
  ContentUpdate: { ... }
});

The ContentBlueprintApi object

publishLegacyDraft() - Publish legacy draft

Publishes a legacy draft of a page created from a blueprint. Legacy drafts will eventually be removed in favor of shared drafts. For now, this method works the same as Publish shared draft.

Usage:

import { ContentBlueprintApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentBlueprintApi(config).publishLegacyDraft({
  draftId: string
  status: string
  ContentBlueprintDraft: { ... }
});
publishSharedDraft() - Publish shared draft

Publishes a shared draft of a page created from a blueprint.

Usage:

import { ContentBlueprintApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentBlueprintApi(config).publishSharedDraft({
  draftId: string
  status: string
  ContentBlueprintDraft: { ... }
});

The ContentIdChildApi object

getAttachments() - Get attachments

Returns the attachments for a piece of content.

Usage:

import { ContentIdChildApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildApi(config).getAttachments({ ...args });
getContentChildren() - Get content children

Returns a map of the direct children of a piece of content. A piece of content has different types of child content, depending on its type. These are the default parent-child content type relationships:

Usage:

import { ContentIdChildApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildApi(config).getContentChildren({ ...args });
getContentChildrenByType() - Get content children by type

Returns all children of a given type, for a piece of content. A piece of content has different types of child content, depending on its type:

Usage:

import { ContentIdChildApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildApi(config).getContentChildrenByType({ ...args });
getContentComments() - Get content comments

Returns the comments on a piece of content.

Usage:

import { ContentIdChildApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildApi(config).getContentComments({ ...args });

The ContentIdChildAttachmentApi object

createAttachments() - Create attachment

Adds an attachment to a piece of content. This method only adds a new attachment. If you want to update an existing attachment, use Create or update attachments.

Usage:

import { ContentIdChildAttachmentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildAttachmentApi(config).createAttachments({
  id: string
  status: string
  createAttachments: { ... }
});
createOrUpdateAttachments() - Create or update attachment

Adds an attachment to a piece of content. If the attachment already exists for the content, then the attachment is updated (i.e. a new version of the attachment is created).

Usage:

import { ContentIdChildAttachmentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildAttachmentApi(config).createOrUpdateAttachments({
  id: string
  status: string
  createAttachments: { ... }
});
updateAttachmentData() - Update attachment data

Updates the binary data of an attachment, given the attachment ID, and optionally the comment and the minor edit field.

Usage:

import { ContentIdChildAttachmentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildAttachmentApi(config).updateAttachmentData({
  id: string
  attachmentId: string
  createAttachments: { ... }
});
updateAttachmentProperties() - Update attachment properties

Updates the attachment properties, i.e. the non-binary data of an attachment like the filename, media-type, comment, and parent container.

Usage:

import { ContentIdChildAttachmentApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdChildAttachmentApi(config).updateAttachmentProperties({
  id: string
  attachmentId: string
  AttachmentUpdate: { ... }
});

The ContentIdDescendantApi object

descendantsOfType() - Get content descendants by type

Returns all descendants of a given type, for a piece of content. This is similar to Get content children by type, except that this method returns child pages at all levels, rather than just the direct child pages.

Usage:

import { ContentIdDescendantApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdDescendantApi(config).descendantsOfType({ ...args });
getContentDescendants() - Get content descendants

Returns a map of the descendants of a piece of content. This is similar to Get content children, except that this method returns child pages at all levels, rather than just the direct child pages.

Usage:

import { ContentIdDescendantApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdDescendantApi(config).getContentDescendants({ ...args });

The ContentIdLabelApi object

addLabelsToContent() - Add labels to content

Adds labels to a piece of content. Does not modify the existing labels.

Usage:

import { ContentIdLabelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdLabelApi(config).addLabelsToContent({
  id: string
  LabelCreateArray: { ... }
});
getLabelsForContent() - Get labels for content

Returns the labels on a piece of content.

Usage:

import { ContentIdLabelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdLabelApi(config).getLabelsForContent({ ...args });
removeLabelFromContent() - Remove label from content

Removes a label from a piece of content. This is similar to Remove label from content using query parameter except that the label name is specified via a path parameter.

Usage:

import { ContentIdLabelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdLabelApi(config).removeLabelFromContent({ ...args });
removeLabelFromContentUsingQueryParameter() - Remove label from content using query parameter

Removes a label from a piece of content. This is similar to Remove label from content except that the label name is specified via a query parameter.

Usage:

import { ContentIdLabelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdLabelApi(config).removeLabelFromContentUsingQueryParameter({ ...args });

The ContentIdNotificationApi object

getWatchesForPage() - Get watches for page

Returns the watches for a page. A user that watches a page will receive receive notifications when the page is updated.

Usage:

import { ContentIdNotificationApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdNotificationApi(config).getWatchesForPage({ ...args });
getWatchesForSpace() - Get watches for space

Returns all space watches for the space that the content is in. A user that watches a space will receive receive notifications when any content in the space is updated.

Usage:

import { ContentIdNotificationApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdNotificationApi(config).getWatchesForSpace({ ...args });

The ContentIdPropertyApi object

createContentProperty() - Create content property

Creates a property for an existing piece of content. For more information about content properties, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).createContentProperty({
  id: string
  ContentPropertyCreate: { ... }
});
createContentPropertyForKey() - Create content property for key

Creates a property for an existing piece of content. For more information about content properties, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).createContentPropertyForKey({
  id: string
  key: string
  ContentPropertyCreateNoKey: { ... }
});
deleteContentProperty() - Delete content property

Deletes a content property. For more information about content properties, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).deleteContentProperty({ ...args });
getContentProperties() - Get content properties

Returns the properties for a piece of content. For more information about content properties, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).getContentProperties({ ...args });
getContentProperty() - Get content property

Returns a content property for a piece of content. For more information, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).getContentProperty({ ...args });
updateContentProperty() - Update content property

Updates an existing content property. This method will also create a new property for a piece of content, if the property key does not exist and the property version is 1. For more information about content properties, see Confluence entity properties.

Usage:

import { ContentIdPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdPropertyApi(config).updateContentProperty({
  id: string
  key: string
  ContentPropertyUpdate: { ... }
});

The ContentIdRestrictionApi object

addGroupToContentRestriction() - Add group to content restriction

Adds a group to a content restriction. That is, grant read or update permission to the group for a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).addGroupToContentRestriction({ ...args });
addRestrictions() - Add restrictions

Adds restrictions to a piece of content. Note, this does not change any existing restrictions on the content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).addRestrictions({
  id: string
  expand: array
  ContentRestrictionUpdateArray: { ... }
});
addUserToContentRestriction() - Add user to content restriction

Adds a user to a content restriction. That is, grant read or update permission to the user for a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).addUserToContentRestriction({ ...args });
deleteRestrictions() - Delete restrictions

Removes all restrictions (read and update) on a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).deleteRestrictions({ ...args });
getContentRestrictionStatusForGroup() - Get content restriction status for group

Returns whether the specified content restriction applies to a group. For example, if a page with id=123 has a read restriction for the admins group, the following request will return true:

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).getContentRestrictionStatusForGroup({ ...args });
getContentRestrictionStatusForUser() - Get content restriction status for user

Returns whether the specified content restriction applies to a user. For example, if a page with id=123 has a read restriction for a user with an account ID of 384093:32b4d9w0-f6a5-3535-11a3-9c8c88d10192, the following request will return true:

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).getContentRestrictionStatusForUser({ ...args });
getRestrictions() - Get restrictions

Returns the restrictions on a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).getRestrictions({ ...args });
getRestrictionsByOperation() - Get restrictions by operation

Returns restrictions on a piece of content by operation. This method is similar to Get restrictions except that the operations are properties of the return object, rather than items in a results array.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).getRestrictionsByOperation({ ...args });
getRestrictionsForOperation() - Get restrictions for operation

Returns the restictions on a piece of content for a given operation (read or update).

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).getRestrictionsForOperation({ ...args });
removeGroupFromContentRestriction() - Remove group from content restriction

Removes a group from a content restriction. That is, remove read or update permission for the group for a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).removeGroupFromContentRestriction({ ...args });
removeUserFromContentRestriction() - Remove user from content restriction

Removes a group from a content restriction. That is, remove read or update permission for the group for a piece of content.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).removeUserFromContentRestriction({ ...args });
updateRestrictions() - Update restrictions

Updates restrictions for a piece of content. This removes the existing restrictions and replaces them with the restrictions in the request.

Usage:

import { ContentIdRestrictionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdRestrictionApi(config).updateRestrictions({
  id: string
  expand: array
  ContentRestrictionUpdateArray: { ... }
});

The ContentIdVersionApi object

deleteContentVersion() - Delete content version

Delete a historical version. This does not delete the changes made to the content in that version, rather the changes for the deleted version are rolled up into the next version. Note, you cannot delete the current version.

Usage:

import { ContentIdVersionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdVersionApi(config).deleteContentVersion({ ...args });
getContentVersion() - Get content version

Returns a version for a piece of content.

Usage:

import { ContentIdVersionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdVersionApi(config).getContentVersion({ ...args });
getContentVersions() - Get content versions

Returns the versions for a piece of content in descending order.

Usage:

import { ContentIdVersionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdVersionApi(config).getContentVersions({ ...args });
restoreContentVersion() - Restore content version

Restores a historical version to be the latest version. That is, a new version is created with the content of the historical version.

Usage:

import { ContentIdVersionApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentIdVersionApi(config).restoreContentVersion({
  id: string
  expand: array
  VersionRestore: { ... }
});

The ContentbodyConvertToApi object

convertContentBody() - Convert content body

Converts a content body from one format to another format.

Usage:

import { ContentbodyConvertToApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new ContentbodyConvertToApi(config).convertContentBody({
  to: string
  spaceKeyContext: string
  contentIdContext: string
  embeddedContentRender: string
  ContentBodyCreate: { ... }
});

The DefaultApi object

copyPageHierarchy() - Copy page hierarchy

Copy page hierarchy allows the copying of an entire hierarchy of pages and their associated properties, permissions and attachments. The id path parameter refers to the content id of the page to copy, and the new parent of this copied page is defined using the destinationPageId in the request body. The titleOptions object defines the rules of renaming page titles during the copy; for example, search and replace can be used in conjunction to rewrite the copied page titles.

Usage:

import { DefaultApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new DefaultApi(config).copyPageHierarchy({
  id: string
  CopyPageHierarchy: { ... }
});
cqlPDCleaner() - Convert user identifiers to account IDs in CQL queries

Converts one or more CQL queries with user identifiers (username or user key) to equivalent CQL queries with account IDs.

Usage:

import { DefaultApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new DefaultApi(config).cqlPDCleaner({
  CQLPersonalDataMigrationRequest: { ... }
});

The GroupApi object

getGroup() - Get group

Returns a user group for a given group name.

Usage:

import { GroupApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new GroupApi(config).getGroup({ ...args });
getGroupMembers() - Get group members

Returns the users that are members of a group.

Usage:

import { GroupApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new GroupApi(config).getGroupMembers({ ...args });
getGroups() - Get groups

Returns all user groups. The returned groups are ordered alphabetically in ascending order by group name.

Usage:

import { GroupApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new GroupApi(config).getGroups({ ...args });

The LongtaskApi object

getTask() - Get long-running task

Returns information about an active long-running task (e.g. space export), such as how long it has been running and the percentage of the task that has completed.

Usage:

import { LongtaskApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new LongtaskApi(config).getTask({ ...args });
getTasks() - Get long-running tasks

Returns information about all active long-running tasks (e.g. space export), such as how long each task has been running and the percentage of each task that has completed.

Usage:

import { LongtaskApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new LongtaskApi(config).getTasks({ ...args });

The RelationApi object

createRelationship() - Create relationship

Creates a relationship between two entities (user, space, content). The 'favourite' relationship is supported by default, but you can use this method to create any type of relationship between two entities.

Usage:

import { RelationApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new RelationApi(config).createRelationship({ ...args });
findSourcesForTarget() - Find target entities related to a source entity

Returns all target entities that have a particular relationship to the source entity. Note, relationships are one way.

Usage:

import { RelationApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new RelationApi(config).findSourcesForTarget({ ...args });
findTargetFromSource() - Find target entities related to a source entity

Returns all target entities that have a particular relationship to the source entity. Note, relationships are one way.

Usage:

import { RelationApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new RelationApi(config).findTargetFromSource({ ...args });

The SearchApi object

search() - Search

Searches for content using the Confluence Query Language (CQL)

Usage:

import { SearchApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SearchApi(config).search({ ...args });

The SearchUserApi object


The SettingsApi object

getSystemInfo() - Get system info

Returns the system information for the Confluence Cloud tenant. This information is used by Atlassian.

Usage:

import { SettingsApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsApi(config).getSystemInfo({ ...args });

The SettingsLookandfeelApi object

getLookAndFeelSettings() - Get look and feel settings

Returns the look and feel settings for the site or a single space. This includes attributes such as the color scheme, padding, and border radius.

Usage:

import { SettingsLookandfeelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsLookandfeelApi(config).getLookAndFeelSettings({ ...args });
resetLookAndFeelSettings() - Reset look and feel settings

Resets the custom look and feel settings for the site or a single space. This changes the values of the custom settings to be the same as the default settings. It does not change which settings (default or custom) are selected. Note, the default space settings are inherited from the current global settings.

Usage:

import { SettingsLookandfeelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsLookandfeelApi(config).resetLookAndFeelSettings({ ...args });
setLookAndFeelSettings() - Set look and feel settings

Sets the look and feel settings to either the default settings or the custom settings, for the site or a single space. Note, the default space settings are inherited from the current global settings.

Usage:

import { SettingsLookandfeelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsLookandfeelApi(config).setLookAndFeelSettings({
  spaceKey: string
  LookAndFeelType: { ... }
});
updateLookAndFeelSettings() - Update look and feel settings

Updates the look and feel settings for the site or for a single space. If custom settings exist, they are updated. If no custom settings exist, then a set of custom settings is created.

Usage:

import { SettingsLookandfeelApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsLookandfeelApi(config).updateLookAndFeelSettings({
  spaceKey: string
  LookAndFeel: { ... }
});

The SettingsThemeApi object

getGlobalTheme() - Get global theme

Returns the globally assigned theme.

Usage:

import { SettingsThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsThemeApi(config).getGlobalTheme({ ...args });
getTheme() - Get theme

Returns a theme. This includes information about the theme name, description, and icon.

Usage:

import { SettingsThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsThemeApi(config).getTheme({ ...args });
getThemes() - Get themes

Returns all themes, not including the default theme.

Usage:

import { SettingsThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SettingsThemeApi(config).getThemes({ ...args });

The SpaceApi object

createPrivateSpace() - Create private space

Creates a new space that is only visible to the creator. This method is the same as the Create space method with permissions set to the current user only. Note, currently you cannot set space labels when creating a space.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).createPrivateSpace({
  SpacePrivateCreate: { ... }
});
createSpace() - Create space

Creates a new space. Note, currently you cannot set space labels when creating a space.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).createSpace({
  SpaceCreate: { ... }
});
deleteSpace() - Delete space

Deletes a space. Note, the space will be deleted in a long running task. Therefore, the space may not be deleted yet when this method has returned. Clients should poll the status link that is returned in the response until the task completes.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).deleteSpace({ ...args });
getContentByTypeForSpace() - Get content by type for space

Returns all content of a given type, in a space. The returned content is ordered by content ID in ascending order.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).getContentByTypeForSpace({ ...args });
getContentForSpace() - Get content for space

Returns all content in a space. The returned content is grouped by type (pages then blogposts), then ordered by content ID in ascending order.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).getContentForSpace({ ...args });
getSpace() - Get space

Returns a space. This includes information like the name, description, and permissions, but not the content in the space.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).getSpace({ ...args });
getSpaceSettings() - Get space settings

Returns the settings of a space. Currently only the routeOverrideEnabled setting can be returned.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).getSpaceSettings({ ...args });
getSpaces() - Get spaces

Returns all spaces. The returned spaces are ordered alphabetically in ascending order by space key.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).getSpaces({ ...args });
updateSpace() - Update space

Updates the name, description, or homepage of a space.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).updateSpace({
  spaceKey: string
  SpaceUpdate: { ... }
});
updateSpaceSettings() - Update space settings

Updates the settings for a space. Currently only the routeOverrideEnabled setting can be updated.

Usage:

import { SpaceApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceApi(config).updateSpaceSettings({
  spaceKey: string
  SpaceSettingsUpdate: { ... }
});

The SpaceSpaceKeyPropertyApi object

createSpaceProperty() - Create space property

Creates a new space property.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).createSpaceProperty({
  spaceKey: string
  SpacePropertyCreate: { ... }
});
createSpacePropertyForKey() - Create space property for key

Creates a new space property. This is the same as POST /space/{spaceKey}/property but the key for the property is passed as a path parameter, rather than in the request body.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).createSpacePropertyForKey({
  spaceKey: string
  key: string
  SpacePropertyCreateNoKey: { ... }
});
deleteSpaceProperty() - Delete space property

Deletes a space property.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).deleteSpaceProperty({ ...args });
getSpaceProperties() - Get space properties

Returns all properties for the given space. Space properties are a key-value storage associated with a space.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).getSpaceProperties({ ...args });
getSpaceProperty() - Get space property

Returns a space property.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).getSpaceProperty({ ...args });
updateSpaceProperty() - Update space property

Updates a space property. Note, you cannot update the key of a space property, only the value.

Usage:

import { SpaceSpaceKeyPropertyApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyPropertyApi(config).updateSpaceProperty({
  spaceKey: string
  key: string
  SpacePropertyUpdate: { ... }
});

The SpaceSpaceKeyThemeApi object

getSpaceTheme() - Get space theme

Returns the theme selected for a space, if one is set. If no space theme is set, this means that the space is inheriting the global look and feel settings.

Usage:

import { SpaceSpaceKeyThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyThemeApi(config).getSpaceTheme({ ...args });
resetSpaceTheme() - Reset space theme

Resets the space theme. This means that the space will inherit the global look and feel settings

Usage:

import { SpaceSpaceKeyThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyThemeApi(config).resetSpaceTheme({ ...args });
setSpaceTheme() - Set space theme

Sets the theme for a space. Note, if you want to reset the space theme to the default Confluence theme, use the 'Reset space theme' method instead of this method.

Usage:

import { SpaceSpaceKeyThemeApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyThemeApi(config).setSpaceTheme({
  spaceKey: string
  ThemeUpdate: { ... }
});

The SpaceSpaceKeyWatchApi object

getWatchersForSpace() - Returns a list of watchers of a space

Returns a list of watchers of a space

Usage:

import { SpaceSpaceKeyWatchApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new SpaceSpaceKeyWatchApi(config).getWatchersForSpace({ ...args });

The TemplateApi object

createContentTemplate() - Create content template

Creates a new content template. Note, blueprint templates cannot be created via the REST API.

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).createContentTemplate({
  ContentTemplateCreate: { ... }
});
getBlueprintTemplates() - Get blueprint templates

Returns all templates provided by blueprints. Use this method to retrieve all global blueprint templates or all blueprint templates in a space.

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).getBlueprintTemplates({ ...args });
getContentTemplate() - Get content template

Returns a content template. This includes information about template, like the name, the space or blueprint that the template is in, the body of the template, and more.

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).getContentTemplate({ ...args });
getContentTemplates() - Get content templates

Returns all content templates. Use this method to retrieve all global content templates or all content templates in a space.

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).getContentTemplates({ ...args });
removeTemplate() - Remove template

Deletes a template. This results in different actions depending on the type of template:

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).removeTemplate({ ...args });
updateContentTemplate() - Update content template

Updates a content template. Note, blueprint templates cannot be updated via the REST API.

Usage:

import { TemplateApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new TemplateApi(config).updateContentTemplate({
  ContentTemplateUpdate: { ... }
});

The UserApi object

addContentWatcher() - Add content watcher

Adds a user as a watcher to a piece of content. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).addContentWatcher({ ...args });
addLabelWatcher() - Add label watcher

Adds a user as a watcher to a label. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).addLabelWatcher({ ...args });
addSpaceWatcher() - Add space watcher

Adds a user as a watcher to a space. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).addSpaceWatcher({ ...args });
getAnonymousUser() - Get anonymous user

Returns information about how anonymous users are represented, like the profile picture and display name.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getAnonymousUser({ ...args });
getBulkUserLookup() - Get multiple users using ids

Returns user details for the ids provided in request.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getBulkUserLookup({ ...args });
getBulkUserMigration() - Get accountIds for users

Returns the accountIds for the users specified in the key or username parameters. Note that multiple key and username parameters can be specified.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getBulkUserMigration({ ...args });
getContentWatchStatus() - Get content watch status

Returns whether a user is watching a piece of content. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getContentWatchStatus({ ...args });
getCurrentUser() - Get current user

Returns the currently logged-in user. This includes information about the user, like the display name, userKey, account ID, profile picture, and more.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getCurrentUser({ ...args });
getGroupMembershipsForUser() - Get group memberships for user

Returns the groups that a user is a member of.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getGroupMembershipsForUser({ ...args });
getUser() - Get user

Returns a user. This includes information about the user, like the display name, userKey, account ID, profile picture, and more.

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).getUser({ ...args });
isWatchingLabel() - Get label watch status

Returns whether a user is watching a label. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).isWatchingLabel({ ...args });
isWatchingSpace() - Get space watch status

Returns whether a user is watching a space. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).isWatchingSpace({ ...args });
removeContentWatcher() - Remove content watcher

Removes a user as a watcher from a piece of content. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).removeContentWatcher({ ...args });
removeLabelWatcher() - Remove label watcher

Removes a user as a watcher from a label. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).removeLabelWatcher({ ...args });
removeSpaceWatch() - Remove space watch

Removes a user as a watcher from a space. Choose the user by doing one of the following:

Usage:

import { UserApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserApi(config).removeSpaceWatch({ ...args });

The UserEmailApi object

getPrivacyUnsafeUserEmail() - Get a user's email

Returns a user's email address. This API is only available to apps approved by Atlassian, according to these guidelines.

Usage:

import { UserEmailApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserEmailApi(config).getPrivacyUnsafeUserEmail({ ...args });

The UserEmailBulkApi object

getPrivacyUnsafeUserEmailBulk() - Bulk fetch of users' email addresses

Returns user email addresses for a set of accountIds. This API is only available to apps approved by Atlassian, according to these guidelines.

Usage:

import { UserEmailBulkApi, Configuration } from 'fetch-confluence';

const config: Configuration = new Configuration({
  fetchApi: yourFetchClient,
  basePath: "<your base path>"
});

const responsePromise = new UserEmailBulkApi(config).getPrivacyUnsafeUserEmailBulk({ ...args });

References

CreateAttachmentsPayload

{
  "title": "CreateAttachmentsPayload",
  "type": "object",
  "properties": {
    "file": {
      "description": "The relative location and name of the attachment to be added to\nthe content.",
      "type": "string",
      "format": "binary"
    },
    "comment": {
      "description": "The comment for the attachment that is being added.\nIf you specify a comment, then every file must have a comment and\nthe comments must be in the same order as the files. Alternatively,\ndon't specify any comments.",
      "type": "string",
      "format": "binary"
    },
    "minorEdit": {
      "description": "If `minorEdits` is set to 'true', no notification email or activity stream\nwill be generated when the attachment is added to the content.",
      "type": "string",
      "format": "binary"
    }
  },
  "required": [
    "file",
    "minorEdit"
  ]
}

AccountIdEmailRecord

{
  "type": "object",
  "required": [
    "accountId",
    "email"
  ],
  "additionalProperties": false,
  "properties": {
    "accountId": {
      "type": "string"
    },
    "email": {
      "type": "string"
    }
  }
}

AccountIdEmailRecordArray

{
  "type": "array",
  "items": {
    "$ref": "#/components/schemas/AccountIdEmailRecord"
  }
}

AffectedObject

{
  "type": "object",
  "required": [
    "name",
    "objectType"
  ],
  "additionalProperties": false,
  "properties": {
    "name": {
      "type": "string"
    },
    "objectType": {
      "type": "string"
    }
  }
}

AttachmentUpdate

{
  "type": "object",
  "required": [
    "version",
    "id",
    "type"
  ],
  "additionalProperties": false,
  "properties": {
    "version": {
      "type": "object",
      "required": [
        "number"
      ],
      "additionalProperties": false,
      "description": "The attachment version. Set this to the current version number of the\nattachment. Note, the version number only needs to be incremented when\nupdating the actual attachment, not its properties.",
      "properties": {
        "number": {
          "type": "integer",
          "format": "int32",
          "description": "The version number."
        }
      }
    },
    "id": {
      "type": "string",
      "description": "The ID of the attachment to be updated."
    },
    "type": {
      "type": "string",
      "description": "Set this to `attachment`.",
      "enum": [
        "attachment"
      ]
    },
    "title": {
      "type": "string",
      "description": "The updated name of the attachment.",
      "maxLength": 255
    },
    "metadata": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "mediaType": {
          "type": "string",
          "description": "The media type of the attachment, e.g. 'img/jpg'."
        },
        "comment": {
          "type": "string",
          "description": "The comment for this update."
        }
      }
    },
    "container": {
      "type": "object",
      "description": "The new content to attach the attachment to.",
      "required": [
        "id",
        "type"
      ],
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string",
          "description": "The `id` of the parent content."
        },
        "type": {
          "type": "string",
          "description": "The content type. You can only attach attachments to content\nof type: `page`, `blogpost`."
        }
      }
    }
  },
  "title": "AttachmentUpdate"
}

AuditRecord

{
  "type": "object",
  "required": [
    "author",
    "remoteAddress",
    "creationDate",
    "summary",
    "description",
    "category",
    "sysAdmin",
    "affectedObject",
    "changedValues",
    "associatedObjects"
  ],
  "additionalProperties": false,
  "properties": {
    "author": {
      "type": "object",
      "required": [
        "type",
        "displayName",
        "operations",
        "username",
        "userKey"
      ],
      "additionalProperties": false,
      "properties": {
        "type": {
          "type": "string",
          "enum": [
            "user"
          ],
          "default": "user"
        },
        "displayName": {
          "type": "string"
        },
        "operations": {
          "type": "object",
          "default": {}
        },
        "username": {
          "type": "string"
        },
        "userKey": {
          "type": "string"
        }
      }
    },
    "remoteAddress": {
      "type": "string"
    },
    "creationDate": {
      "type": "integer",
      "description": "The creation date-time of the audit record, as a timestamp.",
      "format": "int64"
    },
    "summary": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "category": {
      "type": "string"
    },
    "sysAdmin": {
      "type": "boolean"
    },
    "affectedObject": {
      "$ref": "#/components/schemas/AffectedObject"
    },
    "changedValues": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/ChangedValue"
      }
    },
    "associatedObjects": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/AffectedObject"
      }
    }
  }
}

AuditRecordArray

{
  "type": "object",
  "required": [
    "results",
    "start",
    "limit",
    "size",
    "_links"
  ],
  "additionalProperties": false,
  "properties": {
    "results": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/AuditRecord"
      }
    },
    "start": {
      "type": "integer",
      "format": "int32"
    },
    "limit": {
      "type": "integer",
      "format": "int32"
    },
    "size": {
      "type": "integer",
      "format": "int32"
    },
    "_links": {
      "$ref": "#/components/schemas/GenericLinks"
    }
  }
}

AuditRecordCreate

{
  "type": "object",
  "required": [
    "remoteAddress"
1.0.166

4 years ago

1.0.163

4 years ago

1.0.162

4 years ago

1.0.159

4 years ago

1.0.156

4 years ago

1.0.152

4 years ago

1.0.148

5 years ago

1.0.147

5 years ago

1.0.146

5 years ago

1.0.145

5 years ago

1.0.144

5 years ago

1.0.142

5 years ago

1.0.139

5 years ago

1.0.136

5 years ago

1.0.135

5 years ago

1.0.130

5 years ago

1.0.124

5 years ago

1.0.123

5 years ago

1.0.121

5 years ago

1.0.117

5 years ago

1.0.114

5 years ago

1.0.110

5 years ago

1.0.109

5 years ago

1.0.105

5 years ago

1.0.95

5 years ago

1.0.94

5 years ago

1.0.91

5 years ago

1.0.90

5 years ago

1.0.87

5 years ago

1.0.86

5 years ago

1.0.79

5 years ago

1.0.76

5 years ago

1.0.74

5 years ago

1.0.72

5 years ago

1.0.53

5 years ago

1.0.52

5 years ago

1.0.47

5 years ago