Sdriveconnector v1.0

Version 1.0

Connector Overview: This page documents all 11 actions for the Sdriveconnector v1.0.

Misc (11)

POST 1) Initialize Upload

/apexrest/cg/SDrive/v2/upload

Initialize an upload session by specifying the object, file type, and policy map for the file to be uploaded.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

Options (3)

Option Name

Description

Objectid

The Salesforce record ID that the file will be associated with.

Filetype

The MIME type or file extension of the file being uploaded.

Policymap

A JSON map of security policies to apply to the uploaded file.

PUT 3) Complete Upload

/apexrest/cg/SDrive/v2/upload

Complete an upload session that was previously initialized, finalizing the file transfer.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

POST Create Account

/data/v51.0/sobjects/Account

Create a new Account record in Salesforce with the provided name.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

Options (1)

Option Name

Description

Name

The name to assign to the new Account.

POST Create Folder as S3Object

/data/v51.0/sobjects/cg__S3Object__c

Create a new S3Object record in Salesforce, representing a folder or file placeholder, with optional metadata fields.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

Options (7)

Option Name

Description

Cg File Name C

The display name of the file or folder.

Cg Wip C

Indicates whether the record is a work in progress.

Cg Content Type C

The MIME type of the file content.

Cg Is Latest Version C

Whether this record represents the latest version of the file.

Cg Lock State C

The current lock state of the file (e.g., locked, unlocked).

Cg Checked Out By C

The ID of the user who has checked out the file.

Cg File Size In Bytes C

The size of the file in bytes.

POST Create Folder on Account

/data/v51.0/sobjects/cg__AccountFile__c

Create a new AccountFile record linking a file or folder to an Account, with optional metadata.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

Options (8)

Option Name

Description

Cg Account C

The ID of the Account to associate with the file record.

Cg File Name C

The display name of the file or folder.

Cg Wip C

Indicates whether the record is a work in progress.

Cg Content Type C

The MIME type of the file content.

Cg Is Latest Version C

Whether this record represents the latest version of the file.

Cg Lock State C

The current lock state of the file.

Cg Checked Out By C

The ID of the user who has checked out the file.

Cg File Size In Bytes C

The size of the file in bytes.

DELETE DELETE Files

/

Delete one or more file objects by specifying their object name and IDs.

Parameters

Parameter Name

Description

headers

Additional HTTP header name/value pairs to include in the request.

Fileobjectname

The API name of the file object type to delete (e.g., cg__S3Object__c).

Fileobjectids

A comma-separated list of record IDs to delete.

Response Type

The response format expected from the API (e.g. application/json).

GET GET Files

/apexrest/cg/SDrive/v2/files

Retrieve a list of files matching the provided search query.

Parameters

Parameter Name

Description

headers

Additional HTTP header name/value pairs to include in the request.

Searchquery

The search term or query string to filter files.

Response Type

The response format expected from the API (e.g. application/json).

GET Get File Objects To Parents Map

/apexrest/cg/SDrive/v2/fileObjects

Get a mapping from file objects to their parent objects, filtered by object name, parent ID, or folder IDs.

Parameters

Parameter Name

Description

headers

Additional HTTP header name/value pairs to include in the request.

Fileobjectname

The API name of the file object type to include in the map.

Parentobjectid

The ID of a parent object to restrict the results to.

Folderids

A comma-separated list of folder record IDs to include.

Response Type

The response format expected from the API (e.g. application/json).

GET Get Parents To File Objects Map

/apexrest/cg/SDrive/v2/parentObjects

Get a mapping from parent objects to their associated file objects.

Parameters

Parameter Name

Description

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

POST POST Files

/apexrest/cg/SDrive/v2/files

Upload or create new file records and their associated data.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).

PUT PUT Files

/apexrest/cg/SDrive/v2/files

Update existing file records with new data.

Parameters

Parameter Name

Description

Content Type

The content type of the request payload sent to the API (e.g. application/json).

headers

Additional HTTP header name/value pairs to include in the request.

Response Type

The response format expected from the API (e.g. application/json).