Slack. Web. Apps. Datastore
(SlackKit v0.25.0-alpha.0)
View Source
Summary
Functions
Delete items from a datastore in bulk
Get items from a datastore in bulk
Creates or replaces existing items in bulk
Count the number of items in a datastore that match a query
Delete an item from a datastore
Get an item from a datastore
Creates a new item, or replaces an old item with a new item.
Query a datastore for items
Edits an existing item's attributes, or adds a new item if it does not already exist.
Functions
Delete items from a datastore in bulk
Required Params
datastore- name of the datastoreids- IDs of items to be deleted ex:["7c6dd137", "c7d6d731"]
Optional Params
app_id-
Errors the API can return:
unknown_method- This method does not existtoken_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.partial_failure- some items failed to be deletedenterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore put not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to create datastore items.
Get items from a datastore in bulk
Required Params
datastore- name of the datastoreids- items' ids ex:["7c6dd137", "c7d6d731"]
Optional Params
app_id-
Errors the API can return:
unknown_method- This method does not existtoken_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.partial_failure- some items failed to be retrievedenterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore put not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to create datastore items.
Creates or replaces existing items in bulk
Required Params
datastore- name of the datastoreitems- attribute names and values of the items; limit of 25 ex:[{"id": "7c6dd137", "favourite_meal": "Shawarma", "reason": "Who doesn't like Shawarma?"}]
Optional Params
app_id-
Errors the API can return:
unknown_method- This method does not existtoken_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.partial_failure- some items failed to be updatedenterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore put not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to create datastore items.
Count the number of items in a datastore that match a query
Required Params
datastore- Name of the datastore
Optional Params
app_id- Required if calling with user tokenexpression- A query filter expression ex:#artist = :artist_nameexpression_attributes- A map of attributes referenced in expression ex:{ "#artist": "artist" }expression_values- A map of values referenced in expression ex:{ ":artist_name": "Fred Rogers" }
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore query not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to access datastore items.
Delete an item from a datastore
Required Params
datastore- name of the datastoreid- item id
Optional Params
app_id-
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore delete not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to delete datastore items.
Get an item from a datastore
Required Params
datastore- name of the datastoreid- item id
Optional Params
app_id-
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access to the datastore.datastore_error- Datastore error.team_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore get not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to get datastore items.
Creates a new item, or replaces an old item with a new item.
Required Params
datastore- name of the datastoreitem- attribute names and values of the item
Optional Params
app_id-
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore put not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to create datastore items.
Query a datastore for items
Required Params
datastore- Name of the datastore
Optional Params
app_id- Required if calling with user tokencursor- Setcursortonext_cursorreturned by the previous call to list items in the next page ex:5c3e53d5expression- A query filter expression ex:#artist = :artist_nameexpression_attributes- A map of attributes referenced in expression ex:{ "#artist": "artist" }expression_values- A map of values referenced in expression ex:{ ":artist_name": "Fred Rogers" }limit- The maximum number of items to evaluate for a given request (not necessarily the number of matching items). If the given request dataset size exceeds 1 MB before reaching the limit, the returned item count will likely be less than the limit. In any case where there are more items available beyond an imposed limit, anext_cursorvalue will be provided for use in subsequent requests. ex:100
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore query not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to access datastore items.
Edits an existing item's attributes, or adds a new item if it does not already exist.
Required Params
datastore- name of the datastoreitem- attribute names and values to be updated
Optional Params
app_id-
Errors the API can return:
token_revoked- Authentication token is for a deleted user or workspace or the app has been removed when using ausertoken.invalid_arg_name- The method was passed an argument whose name falls outside the bounds of accepted or expected values. This includes very long names and names with non-alphanumeric characters other than_. If you get this error, it is typically an indication that you have made a very malformed API call.two_factor_setup_required- Two factor setup is required.datastore_migration_in_progress- The datastore is currently unavailable due to an in progress Enterprise org migration.team_quota_exceeded- Total number of requests exceeded team quota.invalid_form_data- The method was called via aPOSTrequest withContent-Typeapplication/x-www-form-urlencodedormultipart/form-data, but the form data was either missing or syntactically invalid.invalid_post_type- The method was called via aPOSTrequest, but the specifiedContent-Typewas invalid. Valid types are:application/jsonapplication/x-www-form-urlencodedmultipart/form-datatext/plain.restricted_plan_level- Feature is not available on this teamfatal_error- The server could not complete your operation(s) without encountering a catastrophic error. It's possible some aspect of the operation succeeded before the error was raised.deprecated_endpoint- The endpoint has been deprecated.ratelimited- The request has been ratelimited. Refer to theRetry-Afterheader for when to retry the request.ekm_access_denied- Administrators have suspended the ability to post a message.service_unavailable- The service is temporarily unavailableteam_access_not_granted- The token used is not granted the specific workspace access required to complete this request.app_not_hosted- The app developer is not using a Slack-hosted environment. App datastores are exclusively available for Slack-hosted apps.invalid_arguments- The request is missing required arguments.invalid_array_arg- The method was passed an array as an argument. Please only input valid strings.request_timeout- The method was called via aPOSTrequest, but thePOSTdata was either missing or truncated.account_inactive- Authentication token is for a deleted user or workspace when using abottoken.not_authed- No authentication token provided.internal_error- The server could not complete your operation(s) without encountering an error, likely due to a transient issue on our end. It's possible some aspect of the operation succeeded before the error was raised.enterprise_is_restricted- The method cannot be called from an Enterprise.invalid_datastore- The provided datastore is invalid.no_permission- The workspace token used in this request does not have the permissions necessary to complete the request. Make sure your app is a member of the conversation it's attempting to post a message to.access_denied- Not authorized to access the datastore.datastore_error- Datastore errorteam_added_to_org- The workspace associated with your request is currently undergoing migration to an Enterprise Organization. Web API and other platform operations will be intermittently unavailable until the transition is complete.missing_scope- The token used is not granted the specific scope permissions required to complete this request.missing_post_type- The method was called via aPOSTrequest and included a data payload, but the request did not include aContent-Typeheader.accesslimited- Access to this method is limited on the current networktoken_expired- Authentication token has expiredfree_team_not_allowed- Datastore put not allowed on a free team.invalid_charset- The method was called via aPOSTrequest, but thecharsetspecified in theContent-Typeheader was invalid. Valid charset names are:utf-8iso-8859-1.method_deprecated- The method has been deprecated.invalid_app_id- The app_id provided is not valid for team and user.not_allowed_token_type- The token type used in this request is not allowed.org_login_required- The workspace is undergoing an enterprise migration and will not be available until migration is complete.invalid_auth- Not authorized to create datastore items.