Update Slack integration mapping

put
https://api.box.com/2.0
/integration_mappings/slack/:integration_mapping_id

Updates a Slack integration mapping. Supports updating the Box folder ID and options.

You need Admin or Co-Admin role to use this endpoint.

Request

bearer [ACCESS_TOKEN]
application/json

Path Parameters

stringin pathrequired
11235432

An ID of an integration mapping

Request Body

objectin body

The schema for an integration mapping Box item object for type Slack

stringin bodyoptional
"1234567891"

ID of the mapped item (of type referenced in type)

stringin bodyoptional
"folder"

Type of the mapped item referenced in id

Value is always folder

objectin body

The schema for an integration mapping options object for Slack type.

true

Indicates whether or not channel member access to the underlying box item should be automatically managed. Depending on type of channel, access is managed through creating collaborations or shared links.

Response

application/jsonIntegration mapping

Returns the updated integration mapping object.

application/jsonClient error

Returns a bad_request if an incorrect options was supplied or the Box folder cannot be mapped to this partner_item. Error codes:

  • SERVICE_ACCOUNT_IS_NOT_A_COOWNER_OR_OWNER - service account doesn't have co-owner collaboration or is not an owner of the box_item_id,
  • BOX_FOLDER_EXTERNALLY_OWNED - Box folder must be internally owned to the admin's enterprise,
  • JWT_APP_NOT_AUTHORIZED - JWT authorization error.
application/jsonClient error

Returns not_found if integration mapping object was not found.

application/jsonClient error

An unexpected client error.

put
Update Slack integration mapping
You can now try out some of our APIs live, right here in the documentation.
Log in

Request Example

cURL
curl -X -L PUT "https://api.box.com/2.0/integration_mappings/slack/512521" \
     -H "authorization: Bearer <ACCESS_TOKEN>"  \
     -H 'content-type: application/json'  \
     -d'{
         "options": {
            "is_access_management_disabled": true
        }
    }'
Node
const mapping = await client.integrationMappings.updateSlackIntegrationMapping({
	box_item: {
		id: '12345',
		type: 'folder'
	},
	options: {
		is_access_management_disabled: true
	}
}, {
	integration_mapping_id: integrationMappingId
});

console.log(
    `Slack integration mapping with id ${mapping.id} was updated`
);

Response Example

{
  "id": "12345",
  "type": "integration_mapping",
  "box_item": {
    "id": "12345",
    "type": "folder",
    "etag": "1",
    "name": "Contracts",
    "sequence_id": "3"
  },
  "created_at": "2012-12-12T10:53:43-08:00",
  "created_by": {
    "id": "11446498",
    "type": "user",
    "login": "ceo@example.com",
    "name": "Aaron Levie"
  },
  "integration_type": "slack",
  "is_manually_created": true,
  "modified_at": "2012-12-12T10:53:43-08:00",
  "modified_by": {
    "id": "11446498",
    "type": "user",
    "login": "ceo@example.com",
    "name": "Aaron Levie"
  },
  "options": {},
  "partner_item": {
    "id": "C12378991223",
    "type": "channel",
    "slack_org_id": "E1234567",
    "slack_workspace_id": "T12352314"
  }
}