jolicode / slack-php-api

:hash: PHP Slack Client based on the official OpenAPI specification
https://jolicode.github.io/slack-php-api/
MIT License
222 stars 56 forks source link

works great docs suck #46

Closed ghost closed 5 years ago

ghost commented 5 years ago

Hi,

Finally figured it out, I have update the readme on my loocal clone to make it easier to understand, how do I push this raise pull request so you might want this?

ghost commented 5 years ago

e.g

Usage

Slack used to have a custom integerations section, allot of docs use this, but the new way is building an app.

You need to create an app and get the token for that app to communicate with slack.

Then, use the factory that is provided to create the client:

There are some good examples in this repo /doc/examples

lyrixx commented 5 years ago

Hello

how do I push this raise pull request so you might want this?

Thanks for proposing a pull request. You can read the doc about it there

dev-mansonthomas commented 4 years ago

I agree that docs could be improved :)

I'm stuck with this error : Slack returned error code "missing_scope"

And I don't feel it's specified in the example or docs here what to do with scope.

from the slack doc : https://api.slack.com/legacy/oauth-scopes it seems we have to make some calls to setup scopes.

dev-mansonthomas commented 4 years ago

Found it here : https://api.slack.com/authentication/basics

You can select the scopes to add to your app by heading over to the OAuth & Permissions sidebar.

Scroll down to the Scopes section and click to Add an OAuth Scope.

For example, try adding the chat:write scope to your Bot Token. It'll allow your app to post messages!

Now I get a channel not found, while I specify the correct channel name...