### Thumbnail Metadata Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of Thumbnail metadata, which currently only supports an external URL for referencing a thumbnail image. ```json { "externalUrl": "https://example-file.com/file/123123" } ``` -------------------------------- ### Example Curl Command for setObjects Source: https://developer.atlassian.com/platform/teamwork-graph/build-a-teamwork-graph-connector Provides an example curl command to test or invoke the setObjects function. It demonstrates how to specify the function and the connector name in the URL. ```bash curl '$URL?func=setObjects&connectorName=' ``` -------------------------------- ### Entity Key Examples (JSON) Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes Examples demonstrating different types of Entity Keys, used for linking objects. This includes generic, non-generic, and composed keys, each with specific 'type' and 'value' structures. ```json { "type": "atlassian:document", "value": { "entityId": "a-document-id" } } ``` ```json { "type": "atlassian:branch", "value": { "repositoryId": "repo-123" } } ``` ```json { "type": "atlassian:commit", "value": { "repositoryId": "a-repository-id", "commitHash": "a-commit-hash" } } ``` -------------------------------- ### Example cURL command for getObject function Source: https://developer.atlassian.com/platform/teamwork-graph/build-a-teamwork-graph-connector This is an example cURL command demonstrating how to invoke the `getObject` function. It includes placeholders for the URL, external ID, and connector name, which should be replaced with actual values. ```shell curl '$URL?func=getObject&externalId=&connectorName=' ``` -------------------------------- ### User Reference Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of a UserReference object, which can include account ID, email, and external ID. The required fields depend on whether OAuth is used for authentication. ```json { "accountId": "5b5775502abff9a219", "id": "WELLJST6K", "email": "user@email.com", "externalId" : "external-id-1" } ``` -------------------------------- ### Attachment Object Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of an attachment object, used to represent files associated with an object. It includes properties like URL, title, and mime type. ```json { "url": "https://www.somedomain.com/files/fakefile.pdf", "title": "Fake File", "mimeType": "application/pdf" } ``` -------------------------------- ### ServiceIdOrKeysAssociation Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of a ServiceIdOrKeysAssociation, used to reference services by their identifiers or keys. It specifies the association type and a list of service identifiers. ```json { "updateSequenceNumber": "999", "lastUpdatedAt": "2024-04-16T09:31:32+00:00", "set": [ { "associationType": "serviceIdOrKeys", "values": [ "SVC-123" ] } ] } ``` -------------------------------- ### EntityAssociation Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of an EntityAssociation, used to reference other Atlassian entities like documents. It includes the association type and a list of entity identifiers. ```json { "updateSequenceNumber": "999", "lastUpdatedAt": "2024-04-16T09:31:32+00:00", "set": [ { "associationType": "atlassian:document", "values": [ { "entityId": "my-document-123" } ] } ] } ``` -------------------------------- ### Permissions Access Control Examples (JSON) Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes Examples illustrating how permissions are defined using AccessControl objects. This includes principals like User, Group, Atlassian workspace, and Container, each with specific types and IDs. ```json { "accessControls": [ { "principals": [ { "type": "USER", "id": "user-external-id" }, { "type": "GROUP", "id": "group-external-id" }, { "type": "ATLASSIAN_WORKSPACE" }, { "type": "CONTAINER" } ] } ] } ``` -------------------------------- ### Access Controls Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes Demonstrates how to define access controls for entities, specifying principals like users and groups, or an entire Atlassian workspace. ```json [ { "accessControls": [ { "principals": [ { "type": "USER", "id": "WELLJST6K" }, { "type": "GROUP", "id": "UJHJST6K" } ] } ] }, { "accessControls": [ { "principals": [ { "type": "ATLASSIAN_WORKSPACE" } ] } ] } ] ``` -------------------------------- ### Design Payload Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/design This section provides an example of a JSON payload for a design object, including its ID, display name, description, URL, update timestamp, and specific Atlassian design details. ```APIDOC ## POST /websites/developer_atlassian_platform_teamwork-graph/designs ### Description This endpoint allows for the creation or update of design objects within the Teamwork Graph. ### Method POST ### Endpoint /websites/developer_atlassian_platform_teamwork-graph/designs ### Parameters #### Request Body - **objects** (array) - Required - An array of design objects to be created or updated. - **id** (string) - Required - Unique identifier for the design. - **updateSequenceNumber** (integer) - Required - The sequence number for updates. - **displayName** (string) - Required - The display name of the design. - **description** (string) - Optional - A description of the design. - **url** (string) - Required - The URL to the design file. - **lastUpdatedAt** (string) - Required - The timestamp of the last update in ISO 8601 format. - **atlassian:design** (object) - Required - Atlassian-specific design properties. - **liveEmbedUrl** (string) - Required - The live embed URL for the design. - **status** (string) - Required - The current status of the design (e.g., "READY_FOR_DEVELOPMENT"). - **type** (string) - Required - The type of the design (e.g., "FILE"). ### Request Example ```json { "objects" : [ { "id" : "design-1", "updateSequenceNumber" : 1, "displayName" : "My design", "description" : "My first design", "url" : "https://www.example-design.com/file/XlgwF9hpEiVZHmsToT0ZTU", "lastUpdatedAt" : "2023-07-19T15:27:37.000Z", "atlassian:design" : { "liveEmbedUrl" : "https://example-design.com/embed/1111", "status" : "READY_FOR_DEVELOPMENT", "type" : "FILE" } } ] } ``` ### Response #### Success Response (200) - **message** (string) - A confirmation message indicating the success of the operation. ``` -------------------------------- ### Deploy Forge App using CLI Source: https://developer.atlassian.com/platform/teamwork-graph/build-a-teamwork-graph-connector These commands are used to deploy and install a Forge application. First, `forge deploy` uploads your app's code to the Forge platform. Subsequently, `forge install` links the deployed app to a specific Atlassian site, requiring user interaction to select the site type and enter the site URL. ```bash forge deploy ``` ```bash forge install ``` -------------------------------- ### Test Properties and Example Payload Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/test This section outlines the available properties for defining test configurations and provides an example of a request payload that includes these properties within the Teamwork Graph API. ```APIDOC ## Test Properties This endpoint allows for the definition and retrieval of test properties. ### Method GET (or POST, depending on the specific operation) ### Endpoint /websites/developer_atlassian_platform_teamwork_graph ### Parameters #### Query Parameters None specified in the provided text. #### Request Body None specified in the provided text. ### Response #### Success Response (200) - **status** (string) - Required - The current status of the test. - **testType** (string) - Required - The type of test being performed. - **statusPrecedence** (string) - Optional - The precedence level of the test status. - **version** (string) - Optional - The version of the test. - **environment** (string) - Optional - The environment in which the test is executed. ### Request Example ```json { "objects" : [ { "id" : "test-example-1", "updateSequenceNumber" : 1, "displayName" : "Test noun example", "url" : "https://www.atlassian.com/share/test", "createdAt" : "2024-07-09T14:27:37.000Z", "lastUpdatedAt" : "2024-07-09T14:27:37.000Z", "createdBy" : { "externalId" : "external-id-1" }, "permissions" : { "accessControls" : [ { "principals" : [ { "type" : "ATLASSIAN_WORKSPACE" } ] } ] }, "atlassian:test" : { "status" : "In progress", "testType" : "manual", "statusPrecedence" : "final", "version" : "1.0", "environment" : "mobile" } } ] } ``` ### Response Example (Response structure would mirror the request body, potentially with added metadata or status codes) ``` -------------------------------- ### Basic Bulk Ingestion Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-operations/set-objects This example demonstrates a basic bulk ingestion of a single document object using the `setObjects` method. It includes the document object, properties for tagging, and a connection ID. The response from the API call is captured. ```typescript import { graph } from '@forge/teamwork-graph'; import { types } from '@forge/teamwork-graph'; const document: types.DocumentObject = { // ...common and required properties 'atlassian:document': { type: { category: 'document' }, content: { mimeType: 'text/plain', text: 'Project documentation...' } } }; const request = { objects: [document], properties: { "pull-id": "12334", "timestamp": "12344" }, connectionId: 'connection-id-123' }; const response = await graph.setObjects(request); ``` -------------------------------- ### Deployment Payload Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/deployment This snippet shows an example JSON payload representing a deployment object within the Teamwork Graph API. It includes details about the deployment's schema version, ID, display name, description, URLs, timestamps, creator, updater, container information, permissions, and specific deployment attributes like sequence number, pipeline, environment, state, and duration. ```APIDOC ## POST /websites/developer_atlassian_platform_teamwork-graph ### Description This endpoint is used to create or update deployment information within the Atlassian Developer Platform. ### Method POST ### Endpoint /websites/developer_atlassian_platform_teamwork-graph ### Request Body - **objects** (array) - Required - An array of deployment objects. - **schemaVersion** (string) - Required - The schema version of the deployment object. - **id** (string) - Required - The unique identifier for the deployment. - **updateSequenceNumber** (integer) - Required - The sequence number for updates. - **displayName** (string) - Required - The display name of the deployment. - **description** (string) - Optional - A description of the deployment. - **url** (string) - Required - The URL associated with the deployment. - **createdAt** (string) - Required - The timestamp when the deployment was created (ISO 8601 format). - **createdBy** (object) - Required - Information about the user who created the deployment. - **externalId** (string) - Required - The external ID of the creator. - **lastUpdatedAt** (string) - Required - The timestamp when the deployment was last updated (ISO 8601 format). - **lastUpdatedBy** (object) - Required - Information about the user who last updated the deployment. - **externalId** (string) - Required - The external ID of the last updater. - **containerKey** (object) - Required - Information about the container for the deployment. - **type** (string) - Required - The type of the container (e.g., "atlassian:repository"). - **value** (object) - Required - The value of the container key. - **repositoryId** (string) - Required - The repository ID. - **permissions** (array) - Optional - Permissions associated with the deployment. - **accessControls** (array) - Required - Access control rules. - **principals** (array) - Required - Principals with access. - **type** (string) - Required - The type of principal (e.g., "ATLASSIAN_WORKSPACE"). - **atlassian:deployment** (object) - Required - Specific attributes for Atlassian deployments. - **deploymentSequenceNumber** (integer) - Required - The sequence number of the deployment. - **pipeline** (object) - Required - Information about the pipeline. - **id** (string) - Required - The pipeline ID. - **displayName** (string) - Required - The pipeline display name. - **url** (string) - Required - The pipeline URL. - **environment** (object) - Required - Information about the environment. - **id** (string) - Required - The environment ID. - **displayName** (string) - Required - The environment display name. - **type** (string) - Required - The type of environment (e.g., "staging"). - **label** (string) - Required - The label for the deployment. - **state** (string) - Required - The current state of the deployment (e.g., "in_progress"). - **duration** (integer) - Optional - The duration of the deployment in seconds. - **commands** (array) - Optional - Commands executed during the deployment. - **command** (string) - Required - The name of the command. - **triggeredBy** (object) - Optional - Information about who triggered the deployment. - **accountId** (string) - Required - The account ID of the triggerer. - **email** (string) - Required - The email of the triggerer. ### Request Example ```json { "objects" : [ { "schemaVersion" : "2.0", "id" : "pipelineId/e9c906a7-451f-4fa6-ae1a-c389e2e2d87c/environmentId/8ec94d72-a4fc-4ac0-b31d-c5a595f373ba/deploymentSequenceNumber/100", "updateSequenceNumber" : 1, "displayName" : "Test Deployment", "description" : "A test deployment to staging", "url" : "https://entity.example.com/1", "createdAt" : "2024-07-01T05:00:45Z", "createdBy" : { "externalId" : "external-id-1" }, "lastUpdatedAt" : "2024-07-09T14:27:37.000Z", "lastUpdatedBy" : { "externalId" : "external-id-1" }, "containerKey" : { "type" : "atlassian:repository", "value" : { "repositoryId" : "my-repo-1" } }, "permissions" : [ { "accessControls" : [ { "principals" : [ { "type" : "ATLASSIAN_WORKSPACE" } ] } ] } ], "atlassian:deployment" : { "deploymentSequenceNumber" : 100, "pipeline" : { "id" : "e9c906a7-451f-4fa6-ae1a-c389e2e2d87c", "displayName" : "Test Deployment", "url" : "http://mydeployer.com/project1" }, "environment" : { "id" : "8ec94d72-a4fc-4ac0-b31d-c5a595f373ba", "displayName" : "US East", "type" : "staging" }, "label" : "Release 2018-01-20_08-47-bc2421a", "state" : "in_progress", "duration" : 47, "commands" : [ { "command" : "initiate_deployment_gating" } ], "triggeredBy" : { "accountId" : "5b10ac8d82e05b22cc7d4ef5", "email" : "author@example.com" } } } ] } ``` ### Response #### Success Response (200) - **message** (string) - A success message indicating the deployment information was processed. #### Response Example ```json { "message": "Deployment information processed successfully." } ``` ``` -------------------------------- ### Deal Object Payload Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/deal This snippet shows an example of a JSON payload that can be used to create or update a deal within the Teamwork Graph API. It includes details about the deal's schema, ID, description, URLs, creation and update information, permissions, and specific deal-related attributes. ```APIDOC ## POST /websites/developer_atlassian_platform_teamwork-graph ### Description This endpoint allows for the creation or update of deal objects within the Teamwork Graph API. The request body should contain a JSON object representing the deal with all necessary attributes. ### Method POST ### Endpoint /websites/developer_atlassian_platform_teamwork-graph ### Parameters #### Request Body - **objects** (array) - Required - An array of deal objects to be created or updated. - **schemaVersion** (string) - Required - The schema version of the deal object. - **id** (string) - Required - The unique identifier for the deal. - **updateSequenceNumber** (integer) - Required - A number indicating the sequence of updates. - **description** (string) - Optional - A description of the deal. - **url** (string) - Required - The URL associated with the deal. - **displayName** (string) - Required - The display name of the deal. - **createdAt** (string) - Required - The timestamp when the deal was created (ISO 8601 format). - **createdBy** (object) - Required - Information about the user who created the deal. - **email** (string) - Required - The email address of the creator. - **externalId** (string) - Optional - The external ID of the creator. - **name** (string) - Required - The name of the creator. - **avatar** (string) - Optional - The URL of the creator's avatar. - **lastUpdatedAt** (string) - Required - The timestamp when the deal was last updated (ISO 8601 format). - **lastUpdatedBy** (object) - Required - Information about the user who last updated the deal. - **email** (string) - Required - The email address of the last updater. - **externalId** (string) - Optional - The external ID of the last updater. - **name** (string) - Required - The name of the last updater. - **avatar** (string) - Optional - The URL of the last updater's avatar. - **permissions** (array) - Optional - Permissions associated with the deal. - **accessControls** (array) - Optional - Access control configurations. - **principals** (array) - Optional - Principals with access. - **type** (string) - Required - The type of principal (e.g., "ATLASSIAN_WORKSPACE"). - **atlassian:deal** (object) - Required - Specific attributes for the deal. - **contact** (object) - Optional - Contact information related to the deal. - **email** (string) - Required - The email address of the contact. - **externalId** (string) - Optional - The external ID of the contact. - **name** (string) - Required - The name of the contact. - **avatar** (string) - Optional - The URL of the contact's avatar. - **stage** (string) - Optional - The current stage of the deal. - **status** (string) - Optional - The current status of the deal. - **accountName** (string) - Optional - The name of the associated account. - **lastActivityAt** (string) - Optional - The timestamp of the last activity on the deal (ISO 8601 format). - **event** (string) - Optional - The last event related to the deal. - **dealClosedAt** (string) - Optional - The timestamp when the deal was closed (ISO 8601 format). - **value** (number) - Optional - The value of the deal. - **currencyCode** (string) - Optional - The currency code for the deal value. - **isClosed** (boolean) - Optional - Indicates if the deal is closed. - **collaborators** (array) - Optional - A list of collaborators on the deal. - **email** (string) - Required - The email address of the collaborator. - **externalId** (string) - Optional - The external ID of the collaborator. - **name** (string) - Required - The name of the collaborator. - **avatar** (string) - Optional - The URL of the collaborator's avatar. ### Request Example ```json { "objects" : [ { "schemaVersion" : "2.0", "id" : "deal-1", "updateSequenceNumber" : 1, "description" : "Fix login issue", "url" : "https://deal.example.com/item/1", "displayName" : "Deal Name", "createdAt" : "2024-04-16T09:31:32+00:00", "createdBy" : { "email" : "e-mail@user1.com", "externalId" : "external-id-1", "name" : "John Doe", "avatar" : "https://deal.example.com/avatar/31" }, "lastUpdatedAt" : "2024-04-16T09:31:32+00:00", "lastUpdatedBy" : { "email" : "e-mail@user1.com", "externalId" : "external-id-1", "name" : "John Doe", "avatar" : "https://deal.example.com/avatar/31" }, "permissions" : [ { "accessControls" : [ { "principals" : [ { "type" : "ATLASSIAN_WORKSPACE" } ] } ] } ], "atlassian:deal" : { "contact" : { "email" : "e-mail@user1.com", "externalId" : "external-id-1", "name" : "John Doe", "avatar" : "https://deal.example.com/avatar/31" }, "stage" : "In Progress", "status" : "In Progress", "accountName" : "Deal Name", "lastActivityAt" : "2024-04-16T09:31:32+00:00", "event" : "Deal Created", "dealClosedAt" : "2024-04-16T09:31:32+00:00", "value" : 1000.0, "currencyCode" : "USD", "isClosed" : false, "collaborators" : [ { "email" : "e-mail@user1.com", "externalId" : "external-id-1", "name" : "John Doe", "avatar" : "https://deal.example.com/avatar/31" } ] } } ] } ``` ### Response #### Success Response (200) - **objects** (array) - An array of deal objects that were successfully created or updated. #### Response Example ```json { "objects": [ { "schemaVersion": "2.0", "id": "deal-1", "updateSequenceNumber": 1, "description": "Fix login issue", "url": "https://deal.example.com/item/1", "displayName": "Deal Name", "createdAt": "2024-04-16T09:31:32+00:00", "createdBy": { "email": "e-mail@user1.com", "externalId": "external-id-1", "name": "John Doe", "avatar": "https://deal.example.com/avatar/31" }, "lastUpdatedAt": "2024-04-16T09:31:32+00:00", "lastUpdatedBy": { "email": "e-mail@user1.com", "externalId": "external-id-1", "name": "John Doe", "avatar": "https://deal.example.com/avatar/31" }, "permissions": [ { "accessControls": [ { "principals": [ { "type": "ATLASSIAN_WORKSPACE" } ] } ] } ], "atlassian:deal": { "contact": { "email": "e-mail@user1.com", "externalId": "external-id-1", "name": "John Doe", "avatar": "https://deal.example.com/avatar/31" }, "stage": "In Progress", "status": "In Progress", "accountName": "Deal Name", "lastActivityAt": "2024-04-16T09:31:32+00:00", "event": "Deal Created", "dealClosedAt": "2024-04-16T09:31:32+00:00", "value": 1000.0, "currencyCode": "USD", "isClosed": false, "collaborators": [ { "email": "e-mail@user1.com", "externalId": "external-id-1", "name": "John Doe", "avatar": "https://deal.example.com/avatar/31" } ] } } ] } ``` ``` -------------------------------- ### Example Document Payload Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/document An example JSON payload representing a document object in the Atlassian Platform. This payload demonstrates the structure and typical values for fields like schema version, display name, URL, creation timestamp, parent information, permissions, document type, content, size, labels, reactions, and export links. ```json { "objects": [ { "schemaVersion": "1.0", "id": "my-document", "updateSequenceNumber": 123, "displayName": "My Document", "url": "https://document.com", "thumbnail": { "externalUrl": "https://document-thumbnail.com" }, "createdAt": "2024-04-16T09:01:32+00:00", "parentKey": { "type": "atlassian:document", "value": { "entityId": "another-document" } }, "permissions": [ { "accessControls": [ { "principals": [ { "type": "ATLASSIAN_WORKSPACE" } ] } ] } ], "atlassian:document": { "type": { "category": "document", "iconUrl": "http://example-icon.com/icon/111" }, "content": { "mimeType": "text/plain", "text": "Really large content here..." }, "byteSize": 456, "labels": [ "label1", "label2" ], "reactions": [ { "type": "LIKE", "total": 1 } ], "exportLinks": [ { "mimeType": "text/plain", "url": "http://localhost" } ] }, "containerKey": { "type": "atlassian:space", "value": { "entityId": "CFG3W7TKJ" } } } ] } ``` -------------------------------- ### Document Object Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-operations/set-objects This example demonstrates the structure of a `DocumentObject` for ingestion into the Teamwork Graph. It includes schema version, ID, update sequence number, display name, URL, timestamps, permissions, and specific document content details. ```typescript import { types } from '@forge/teamwork-graph'; const document: types.DocumentObject = { schemaVersion: '1.0', id: 'doc-123', updateSequenceNumber: 123, displayName: 'API Documentation', url: 'https://example.com/doc' createdAt: '2024-01-15T10:00:00Z', lastUpdatedAt: '2024-01-20T14:30:00Z', permissions: [{ accessControls: [{ principals: [{ type: 'ATLASSIAN_WORKSPACE' }] }] }], 'atlassian:document': { type: { category: 'document' }, content: { mimeType: 'text/plain', text: 'Document content...' } } }; ``` -------------------------------- ### Example Commit and Repository Payload Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/commit An example JSON payload demonstrating the structure of repository and commit objects. This payload includes details like repository ID, display name, commit message, author information, and file changes. ```json { "objects" : [ { "id" : "repo-1", "updateSequenceNumber" : 1, "displayName" : "My repository", "description" : "My test repo", "url" : "https://bitbucket.org/my-project/my-repo/src/master/", "lastUpdatedAt" : "2023-07-19T15:27:37.000Z", "atlassian:repository" : { "forkOf" : "repo-2", "avatar" : "avatar.png", "avatarDescription" : "test icon" } }, { "id" : "commit-1", "updateSequenceNumber" : 1, "displayName" : "Fixed bug 111", "description" : "SAI-123 A commit that fixes things", "url" : "https://bitbucket.org/my-project/my-repo/src/master/", "lastUpdatedAt" : "2023-07-19T15:27:37.000Z", "containerKey" : { "type" : "atlassian:repository", "value" : { "repositoryId" : "repo-1" } }, "owners" : [ { "externalId" : "external-id-1", "email" : "user2@example.com" } ], "atlassian:commit" : { "flags" : [ "MERGE_COMMIT" ], "fileCount" : 34, "files" : [ { "path" : "a/b/c", "url" : "https://url.com/a/b/c", "changeType" : "ADDED", "linesAdded" : 23, "linesRemoved" : 0 } ] } } ] } ``` -------------------------------- ### setObjects Function Integration Source: https://developer.atlassian.com/platform/teamwork-graph/build-a-teamwork-graph-connector Details on how to use the setObjects function, including its purpose, parameters, and an example curl command. ```APIDOC ## POST /websites/developer_atlassian_platform_teamwork-graph ### Description The `setObjects` function fetches connector configuration, retrieves data from Google Drive using API Key and `folderId`, transforms the data into `atlassian:document` format, and integrates it into Atlassian's Teamwork Graph. ### Method POST ### Endpoint /websites/developer_atlassian_platform_teamwork-graph ### Parameters #### Query Parameters - **func** (string) - Required - Specifies the function to call, should be 'setObjects'. - **connectorName** (string) - Required - The name of the connector configuration to fetch from the key-value store. ### Request Example ```bash curl '$URL?func=setObjects&connectorName=' ``` ### Response #### Success Response (200) - **documents** (array) - A list of transformed documents ready for the Teamwork Graph. #### Response Example ```json { "documents": [ { "@context": "http://schema.atlassian.com/representation/v1/context.jsonld", "@type": "atlassian:document", "document": { "@type": "atlassian:document", "blocks": [ { "@type": "atlassian:paragraph", "content": [ { "@type": "atlassian:text", "text": "Example transformed content from Google Drive." } ] } ] } } ] } ``` ``` -------------------------------- ### Teamwork Graph API Overview Source: https://developer.atlassian.com/platform/teamwork-graph/api-reference/overview This section provides an overview of the Teamwork Graph API, its purpose, and how to get started. It highlights the EAP status, required scopes, and important considerations for developers. ```APIDOC ## Teamwork Graph API Overview ### Description The Teamwork Graph API provides unified access to data across Atlassian apps and connected external tools. It is currently available through Forge's Early Access Program (EAP). ### Key Information - **EAP Status**: Unsupported and subject to change. Install apps only in test organizations. - **Required Scopes**: `read:graph:jira` or `read:graph:confluence`. - **Data Access**: Provides access to Teamwork Graph data across your entire organization, respecting end-user permissions. - **Limitations**: Significant limitations apply during EAP. Refer to the 'Limitations and considerations' document for details. - **EAP Access**: Must be part of the EAP. Express interest via the provided form. ### Resources - **Reference Documentation**: Explore API object types and relationship types. - [See object types](/object-types) - [See relationship types](/relationship-types) - **Get Started**: Tutorial on how to call the Teamwork Graph API. - [See tutorial](/get-started) - **Example Apps**: - [Forge Teamwork Graph Dashboards Widget](/example-apps/dashboards-widget) - [Teamwork Graph-powered Onboarding Assistant](/example-apps/onboarding-assistant) ``` -------------------------------- ### IssueIdOrKeysAssociation Example Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/common-properties-and-shapes An example of an IssueIdOrKeysAssociation, used to reference Jira issues by their IDs or keys. It specifies the association type and a list of issue identifiers. ```json { "updateSequenceNumber": "999", "lastUpdatedAt": "2024-04-16T09:31:32+00:00", "set": [ { "associationType": "issueIdOrKeys", "values": [ "TEST-1" ] } ] } ``` -------------------------------- ### Example Video Payload Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/video A sample JSON object demonstrating the structure and typical values for video properties. This payload includes basic video information, permissions, and detailed 'atlassian:video' object with text tracks, chapters, and contributors. ```json { "schemaVersion": "1.0", "id": "video-001", "updateSequenceNumber": 1, "displayName": "Product Demo Video", "description": "A comprehensive product demonstration showcasing key features and capabilities", "url": "https://www.loom.com/share/59105659e3b84d2d8491bcc8f608284d", "createdAt": "2024-01-15T10:00:00.000Z", "lastUpdatedAt": "2024-01-20T14:30:00.000Z", "permissions": [ { "action": "read", "accessControls": [ { "principals": [ { "type": "EVERYONE" } ] } ] }, { "action": "search", "accessControls": [ { "principals": [ { "type": "MUST_HAVE_VIEWED" } ] } ] } ], "atlassian:video": { "thumbnailUrl": "https://cdn.loom.com/sessions/thumbnails/59105659e3b84d2d8491bcc8f608284d-thumbnail.jpg", "embedUrl": "https://www.loom.com/embed/59105659e3b84d2d8491bcc8f608284d", "durationInSeconds": 503, "width": 1920, "height": 1080, "commentCount": 12, "textTracks": [ { "name": "English subtitles", "locale": "en-US", "cues": [ { "id": "cue-intro", "startTimeInSeconds": 0, "endTimeInSeconds": 5.5, "text": "Welcome to our product demonstration. Today we'll be exploring..." }, { "id": "cue-features", "startTimeInSeconds": 90, "endTimeInSeconds": 120, "text": "Let's take a look at the key features that make this product stand out." } ] } ], "chapters": [ { "startTimeInSeconds": 0, "title": "Introduction" }, { "startTimeInSeconds": 90, "title": "Key Features" }, { "startTimeInSeconds": 220, "title": "Advanced Capabilities" }, { "startTimeInSeconds": 350, "title": "Conclusion" } ], "contributors": [ { "user": { "externalId": "user-123", "email": "demo@example.com" }, "interactionCount": 5 }, { "user": { "externalId": "user-456", "email": "reviewer@example.com" }, "interactionCount": 3 } ] } } ``` -------------------------------- ### Example Video Payload Source: https://developer.atlassian.com/platform/teamwork-graph/connector-reference/object-types-connectors/video A complete JSON payload demonstrating the structure and typical values for a video object, including all defined properties. ```APIDOC ## Example Video Payload ```json { "schemaVersion": "1.0", "id": "video-001", "updateSequenceNumber": 1, "displayName": "Product Demo Video", "description": "A comprehensive product demonstration showcasing key features and capabilities", "url": "https://www.loom.com/share/59105659e3b84d2d8491bcc8f608284d", "createdAt": "2024-01-15T10:00:00.000Z", "lastUpdatedAt": "2024-01-20T14:30:00.000Z", "permissions": [ { "action": "read", "accessControls": [ { "principals": [ { "type": "EVERYONE" } ] } ] }, { "action": "search", "accessControls": [ { "principals": [ { "type": "MUST_HAVE_VIEWED" } ] } ] } ], "atlassian:video": { "thumbnailUrl": "https://cdn.loom.com/sessions/thumbnails/59105659e3b84d2d8491bcc8f608284d-thumbnail.jpg", "embedUrl": "https://www.loom.com/embed/59105659e3b84d2d8491bcc8f608284d", "durationInSeconds": 503, "width": 1920, "height": 1080, "commentCount": 12, "textTracks": [ { "name": "English subtitles", "locale": "en-US", "cues": [ { "id": "cue-intro", "startTimeInSeconds": 0, "endTimeInSeconds": 5.5, "text": "Welcome to our product demonstration. Today we'll be exploring..." }, { "id": "cue-features", "startTimeInSeconds": 90, "endTimeInSeconds": 120, "text": "Let's take a look at the key features that make this product stand out." } ] } ], "chapters": [ { "startTimeInSeconds": 0, "title": "Introduction" }, { "startTimeInSeconds": 90, "title": "Key Features" }, { "startTimeInSeconds": 220, "title": "Advanced Capabilities" }, { "startTimeInSeconds": 350, "title": "Conclusion" } ], "contributors": [ { "user": { "externalId": "user-123", "email": "demo@example.com" }, "interactionCount": 5 }, { "user": { "externalId": "user-456", "email": "reviewer@example.com" }, "interactionCount": 3 } ] } } ``` ```