Repository navigation
Move sample apps into samples/ and tidy up docs #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| # Contributing | ||
|
|
||
| Thanks for helping improve the Buffer sample apps. | ||
|
|
||
| ## What we accept | ||
|
|
||
| - **Pull requests for fixes and improvements** to the existing samples are welcome. | ||
| - **New samples** aren't accepted at the moment. If you have an idea for one, please [open an issue](../../issues) instead. | ||
| - **Bugs and suggestions** can be reported by [opening an issue](../../issues). | ||
|
|
||
| ## Guidelines | ||
|
|
||
| - Keep each sample small and copyable. A change should teach one clear Buffer API practice. | ||
| - Include a test when you change behavior. | ||
| - Avoid adding frameworks or dependencies unless they make the example clearer. | ||
| - Before opening a pull request, run the sample's checks. For the Node.js samples, that's `npm test` and `npm run lint`. | ||
| - Never commit `.env` files, certificates, client secrets, sessions, or real tokens. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,58 +1,69 @@ | ||
| # Buffer Sample Apps | ||
|
|
||
| A collection of sample applications that show how to build on the Buffer API. Each sample is a small, self-contained project you can clone, run, and use as a starting point for your own build. | ||
|
|
||
| > **Note:** These samples are meant for learning and prototyping. Make sure to review and adapt them to your own security, error-handling, and scaling needs before using them in production. | ||
|
|
||
| ### Prerequisites | ||
|
|
||
| ## Samples | ||
|
|
||
| | Sample | What it shows | Stack | | ||
| | --- | --- | --- | | ||
| | [App client starter app](samples/app-client-starter-app) | A third-party app that connects a Buffer account over OAuth 2.0 with PKCE, lists its channels, and adds a draft post to a channel's queue. | Node.js, Express | | ||
|
|
||
| ## Prerequisites | ||
|
|
||
| - A [Buffer](https://buffer.com) account | ||
| - API access credentials - see the [Buffer developer docs](https://developers.buffer.com/guides/authentication.html) for how to get them | ||
| - API access credentials. See the [Buffer developer docs](https://developers.buffer.com/guides/authentication.html) for how to get them. | ||
| - Any language-specific tooling listed in the sample's own README | ||
|
|
||
| ## Repository structure | ||
| Each sample app lives in its own folder with everything it needs to run: | ||
|
|
||
| All sample apps live in the `samples/` directory. Each one has its own folder with everything it needs to run: | ||
|
|
||
| ``` | ||
| . | ||
| ├── sample-app-name/ | ||
| │ ├── README.md # Setup and usage instructions for this sample | ||
| │ ├── .env.example # Environment variables the sample needs | ||
| │ └── ... # Source code | ||
| ├── another-sample/ | ||
| │ └── ... | ||
| ├── samples/ | ||
| │ ├── sample-app-name/ | ||
| │ │ ├── README.md # Setup and usage instructions for this sample | ||
| │ │ ├── .env.example # Environment variables the sample needs | ||
| │ │ └── ... # Source code | ||
| │ └── another-sample/ | ||
| │ └── ... | ||
| ├── CONTRIBUTING.md | ||
| ├── LICENSE | ||
| └── README.md | ||
| ``` | ||
|
|
||
| ### Run a sample app | ||
| ## Run a sample app | ||
|
|
||
| 1. Clone the repository: | ||
| ```bash | ||
|
|
||
| ```bash | ||
| git clone https://github.com/bufferapp/buffer-sample-apps.git | ||
| cd buffer-sample-apps | ||
| ``` | ||
| ``` | ||
|
|
||
| 2. Move into the sample you want to try: | ||
| ```bash | ||
| cd sample-app-name | ||
| ``` | ||
|
|
||
|
|
||
| ```bash | ||
| cd samples/sample-app-name | ||
| ``` | ||
|
|
||
| 3. Follow the setup instructions in that sample's `README.md`. | ||
| Never commit your API credentials. Each sample reads them from environment variables - copy `.env.example` to `.env` and fill in your own values. | ||
|
|
||
| Never commit your API credentials. Each sample reads them from environment variables: copy `.env.example` to `.env` and fill in your own values. | ||
|
|
||
| ## Resources | ||
|
|
||
| - [Buffer developer docs](https://developers.buffer.com) | ||
| - [Buffer Help Center](https://support.buffer.com) | ||
|
|
||
| ## Contributing | ||
|
|
||
| These sample apps are provided as-is for educational purposes. They're maintained on a best-effort basis and aren't covered by Buffer's product support or service-level agreements. | ||
|
|
||
| We welcome issues and suggestions for improvements. If you spot a bug or have an idea for a new sample, please [open an issue](../../issues). At the moment we don't accept direct contributions of new samples. | ||
| These sample apps are provided as-is for educational purposes. They're maintained on a best-effort basis and aren't covered by Buffer's product support or service-level agreements. | ||
|
|
||
| See [CONTRIBUTING.md](CONTRIBUTING.md) for what we accept and how to contribute. | ||
|
|
||
| ## License | ||
| This project is licensed under the MIT License. See the [LICENSE](./LICENSE) file for details. | ||
|
|
||
| This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details. |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
app-client-starter-app/package-lock.json → .../app-client-starter-app/package-lock.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
app-client-starter-app/package.json → samples/app-client-starter-app/package.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🔎 Supported by static analysis
🏁 Script executed:
Repository: bufferapp/buffer-sample-apps
Length of output: 4871
Clarify the zero-delay rate-limit behavior.
Retry-After: 0does not trigger a retry, and the error omits the wait-time suffix. Update the README to describe the positive-delay condition and this response behavior.Suggested documentation fix
📝 Committable suggestion
🤖 Prompt for AI Agents