{"action":"created","issue":{"url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/663","repository_url":"https://api.github.com/repos/discordapp/discord-api-docs","labels_url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/663/labels{/name}","comments_url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/663/comments","events_url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/663/events","html_url":"https://github.com/discordapp/discord-api-docs/issues/663","id":354045469,"node_id":"MDU6SXNzdWUzNTQwNDU0Njk=","number":663,"title":"Search Bar Functionality","user":{"login":"Skillz4Killz","id":23035000,"node_id":"MDQ6VXNlcjIzMDM1MDAw","avatar_url":"https://avatars3.githubusercontent.com/u/23035000?v=4","gravatar_id":"","url":"https://api.github.com/users/Skillz4Killz","html_url":"https://github.com/Skillz4Killz","followers_url":"https://api.github.com/users/Skillz4Killz/followers","following_url":"https://api.github.com/users/Skillz4Killz/following{/other_user}","gists_url":"https://api.github.com/users/Skillz4Killz/gists{/gist_id}","starred_url":"https://api.github.com/users/Skillz4Killz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Skillz4Killz/subscriptions","organizations_url":"https://api.github.com/users/Skillz4Killz/orgs","repos_url":"https://api.github.com/users/Skillz4Killz/repos","events_url":"https://api.github.com/users/Skillz4Killz/events{/privacy}","received_events_url":"https://api.github.com/users/Skillz4Killz/received_events","type":"User","site_admin":false},"labels":[{"id":363528567,"node_id":"MDU6TGFiZWwzNjM1Mjg1Njc=","url":"https://api.github.com/repos/discordapp/discord-api-docs/labels/feature%20request","name":"feature request","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2018-08-25T21:40:47Z","updated_at":"2018-09-01T21:48:00Z","closed_at":null,"author_association":"NONE","body":"One of the coolest things on discord is how amazing it's search bar works. Unfortunately, there is no way to interact with it using a bot that I am aware of. Instead i would have to fetch hundreds of thousands if not millions of messages depending on the servers activity and size in order to get the same functionality.\r\n\r\nIs it possible to add this functionality so a request could be made something like:\r\n\r\n```js\r\nGET /search/?in:#channel&filterText=\"keyword\"\r\n```\r\nWhich could send back any and all necessary messages instead of having to fetch so many messages in a loop."},"comment":{"url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/comments/417889299","html_url":"https://github.com/discordapp/discord-api-docs/issues/663#issuecomment-417889299","issue_url":"https://api.github.com/repos/discordapp/discord-api-docs/issues/663","id":417889299,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNzg4OTI5OQ==","user":{"login":"Geo1088","id":4165301,"node_id":"MDQ6VXNlcjQxNjUzMDE=","avatar_url":"https://avatars0.githubusercontent.com/u/4165301?v=4","gravatar_id":"","url":"https://api.github.com/users/Geo1088","html_url":"https://github.com/Geo1088","followers_url":"https://api.github.com/users/Geo1088/followers","following_url":"https://api.github.com/users/Geo1088/following{/other_user}","gists_url":"https://api.github.com/users/Geo1088/gists{/gist_id}","starred_url":"https://api.github.com/users/Geo1088/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Geo1088/subscriptions","organizations_url":"https://api.github.com/users/Geo1088/orgs","repos_url":"https://api.github.com/users/Geo1088/repos","events_url":"https://api.github.com/users/Geo1088/events{/privacy}","received_events_url":"https://api.github.com/users/Geo1088/received_events","type":"User","site_admin":false},"created_at":"2018-09-01T21:48:00Z","updated_at":"2018-09-01T21:48:00Z","author_association":"CONTRIBUTOR","body":"Apart from the analytics side of things: I don't intend to develop this feature myself, as all of my bots are application-specific, but I could also see this feature being useful for pruning messages via general-purpose moderation bots, which could be given a search string in the same format as the search bar uses and delete all the messages that match it.\r\n\r\n(An obvious limitation to the usefulness of something like this would be that messages older than two weeks can't be deleted via the bulk delete method (iirc), but bots could easily check themselves for messages in the results to fall within this time frame, and such a feature would still be useful regardless.)"}}
{"actor":{"display_login":"Geo1088"}}