forked from slack-ruby/slack-api-ref
-
Notifications
You must be signed in to change notification settings - Fork 2
/
chat.update.json
112 lines (112 loc) · 8.16 KB
/
chat.update.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
{
"group": "chat",
"name": "chat.update",
"deprecated": false,
"desc": "Updates a message.",
"args": {
"channel": {
"required": true,
"desc": "Channel containing the message to be updated.",
"type": "channel"
},
"ts": {
"required": true,
"desc": "Timestamp of the message to be updated.",
"type": "timestamp"
},
"as_user": {
"required": false,
"desc": "Pass true to update the message as the authed user. Bot users in this context are considered authed users.",
"type": "boolean"
},
"attachments": {
"required": false,
"desc": "A JSON-based array of structured attachments, presented as a URL-encoded string. This field is required when not presenting text. If you don't include this field, the message's previous attachments will be retained. To remove previous attachments, include an empty array for this field.",
"type": "string"
},
"blocks": {
"required": false,
"desc": "A JSON-based array of structured blocks, presented as a URL-encoded string. If you don't include this field, the message's previous blocks will be retained. To remove previous blocks, include an empty array for this field.",
"type": "blocks[] as string"
},
"file_ids": {
"required": false,
"desc": "Array of new file ids that will be sent with this message.",
"type": "array"
},
"link_names": {
"required": false,
"desc": "Find and link channel names and usernames. Defaults to none. If you do not specify a value for this field, the original value set for the message will be overwritten with the default, none.",
"type": "boolean"
},
"parse": {
"required": false,
"desc": "Change how messages are treated. Defaults to client, unlike chat.postMessage. Accepts either none or full. If you do not specify a value for this field, the original value set for the message will be overwritten with the default, client.",
"type": "string"
},
"reply_broadcast": {
"required": false,
"desc": "Broadcast an existing thread reply to make it visible to everyone in the channel or conversation.",
"type": "boolean"
},
"text": {
"required": false,
"desc": "New text for the message, using the default formatting rules. It's not required when presenting blocks or attachments.",
"type": "string"
}
},
"response": {
"examples": [
"{\n \"ok\": true,\n \"channel\": \"C024BE91L\",\n \"ts\": \"1401383885.000061\",\n \"text\": \"Updated text you carefully authored\",\n \"message\": {\n \"text\": \"Updated text you carefully authored\",\n \"user\": \"U34567890\"\n }\n}",
"{\n \"ok\": false,\n \"error\": \"cant_update_message\"\n}"
]
},
"errors": {
"message_not_found": "No message exists with the requested timestamp.",
"cant_update_message": "Authenticated user does not have permission to update this message.",
"cant_broadcast_message": "Unable to broadcast this message.",
"update_failed": "Internal update failure.",
"channel_not_found": "Value passed for channel was invalid.",
"team_not_found": "Team associated with the message and channel could not be found.",
"edit_window_closed": "The message cannot be edited due to the team message edit settings.",
"msg_too_long": "Message text is too long.",
"too_many_attachments": "Too many attachments were provided with this message. A maximum of 100 attachments are allowed on a message.",
"no_dual_broadcast_content_update": "Can't broadcast an old reply and update the content at the same time.",
"no_text": "No message text provided.",
"as_user_not_supported": "The as_user parameter does not function with workspace apps.",
"is_inactive": "The message cannot be edited within a frozen, archived or deleted channel.",
"invalid_blocks": "The blocks were invalid for the requesting user.",
"invalid_attachments": "The attachments were invalid.",
"external_channel_migrating": "The channel is in the process of migrating and so the message cannot be updated at this time.",
"slack_connect_file_link_sharing_blocked": "Admin has disabled Slack File sharing in all Slack Connect communications.",
"not_authed": "No authentication token provided.",
"invalid_auth": "Some aspect of authentication cannot be validated. Either the provided token is invalid or the request originates from an IP address disallowed from making the request.",
"account_inactive": "Authentication token is for a deleted user or workspace when using a bot token.",
"token_revoked": "Authentication token is for a deleted user or workspace or the app has been removed when using a user token.",
"token_expired": "Authentication token has expired.",
"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.",
"org_login_required": "The workspace is undergoing an enterprise migration and will not be available until migration is complete.",
"ekm_access_denied": "Administrators have suspended the ability to post a message.",
"missing_scope": "The token used is not granted the specific scope permissions required to complete this request.",
"not_allowed_token_type": "The token type used in this request is not allowed.",
"method_deprecated": "The method has been deprecated.",
"deprecated_endpoint": "The endpoint has been deprecated.",
"two_factor_setup_required": "Two factor setup is required.",
"enterprise_is_restricted": "The method cannot be called from an Enterprise.",
"team_access_not_granted": "The token used is not granted the specific workspace access required to complete this request.",
"invalid_arguments": "The method was either called with invalid arguments or some detail about the arguments passed are invalid, which is more likely when using complex arguments like blocks or attachments.",
"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.",
"invalid_array_arg": "The method was passed an array as an argument. Please only input valid strings.",
"invalid_charset": "The method was called via a POST request, but the charset specified in the Content-Type header was invalid. Valid charset names are: utf-8 iso-8859-1.",
"invalid_form_data": "The method was called via a POST request with Content-Type application/x-www-form-urlencoded or multipart/form-data, but the form data was either missing or syntactically invalid.",
"invalid_post_type": "The method was called via a POST request, but the specified Content-Type was invalid. Valid types are: application/json application/x-www-form-urlencoded multipart/form-data text/plain.",
"missing_post_type": "The method was called via a POST request and included a data payload, but the request did not include a Content-Type header.",
"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.",
"ratelimited": "The request has been ratelimited. Refer to the Retry-After header for when to retry the request.",
"accesslimited": "Access to this method is limited on the current network.",
"request_timeout": "The method was called via a POST request, but the POST data was either missing or truncated.",
"service_unavailable": "The service is temporarily unavailable.",
"fatal_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.",
"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."
}
}