Skip to content

Commit ec1dd6d

Browse files
authored
Update README.md
1 parent 7663432 commit ec1dd6d

File tree

1 file changed

+64
-10
lines changed

1 file changed

+64
-10
lines changed

Diff for: β€ŽREADME.md

+64-10
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,73 @@
11
# MessageMedia Webhooks PHP SDK
22
[![Travis Build Status](https://api.travis-ci.org/messagemedia/webhooks-php-sdk.svg?branch=master)](https://travis-ci.org/messagemedia/webhooks-php-sdk)
3+
[![Pull Requests Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat)](http://makeapullrequest.com)
34
[![PHP version](https://badge.fury.io/ph/messagemedia%2Fwebhooks-sdk.svg)](https://badge.fury.io/ph/messagemedia%2Fwebhooks-sdk)
45

56
The MessageMedia Webhooks allows you to subscribe to one or several events and when one of those events is triggered, an HTTP request is sent to the URL of your choice along with the message or payload. In simpler terms, it allows applications to "speak" to one another and get notified automatically when something new happens.
67

7-
## ⭐️ Installing via Composer
8+
![Webhooks Flow](http://i66.tinypic.com/2ufxf81.jpg)
9+
10+
## Table of Contents
11+
* [Authentication](#closed_lock_with_key-authentication)
12+
* [Errors](#interrobang-errors)
13+
* [Information](#newspaper-information)
14+
* [Slack and Mailing List](#slack-and-mailing-list)
15+
* [Bug Reports](#bug-reports)
16+
* [Contributing](#contributing)
17+
* [Installation](#star-installation)
18+
* [Get Started](#clapper-get-started)
19+
* [API Documentation](#closed_book-api-documentation)
20+
* [Need help?](#confused-need-help)
21+
* [License](#page_with_curl-license)
22+
23+
## :closed_lock_with_key: Authentication
24+
25+
Authentication is done via API keys. Sign up at https://developers.messagemedia.com/register/ to get your API keys.
26+
27+
Requests are authenticated using HTTP Basic Auth or HMAC. Provide your API key as the auth_user_name and API secret as the auth_password.
28+
29+
## :interrobang: Errors
30+
31+
Our API returns standard HTTP success or error status codes. For errors, we will also include extra information about what went wrong encoded in the response as JSON. The most common status codes are listed below.
32+
33+
#### HTTP Status Codes
34+
35+
| Code | Title | Description |
36+
|-----------|-------------|-------------|
37+
| 400 | Invalid Request | The request was invalid |
38+
| 401 | Unauthorized | Your API credentials are invalid |
39+
| 403 | Disabled feature | Feature not enabled |
40+
| 404 | Not Found | The resource does not exist |
41+
| 50X | Internal Server Error | An error occurred with our API |
42+
43+
## :newspaper: Information
44+
45+
#### Slack and Mailing List
46+
47+
If you have any questions, comments, or concerns, please join our Slack channel:
48+
https://developers.messagemedia.com/collaborate/slack/
49+
50+
Alternatively you can email us at:
51+
52+
53+
#### Bug reports
54+
55+
If you discover a problem with the SDK, we would like to know about it. You can raise an [issue](https://github.com/messagemedia/signingkeys-nodejs-sdk/issues) or send an email to: [email protected]
56+
57+
#### Contributing
58+
59+
We welcome your thoughts on how we could best provide you with SDKs that would simplify how you consume our services in your application. You can fork and create pull requests for any features you would like to see or raise an [issue](https://github.com/messagemedia/signingkeys-nodejs-sdk/issues)
60+
61+
## :star: Installation
862
Run the Composer command to install the latest stable version of the Messages SDK:
963
```
1064
composer require messagemedia/webhooks-sdk
1165
```
1266

13-
## 🎬 Get Started
67+
## :clapper: Get Started
1468
It's easy to get started. Simply enter the API Key and secret you obtained from the [MessageMedia Developers Portal](https://developers.messagemedia.com) into the code snippet below.
1569

16-
### πŸš€ Create a webhook
70+
### Create a webhook
1771
```php
1872
<?php
1973
require_once('vendor/autoload.php');
@@ -36,7 +90,7 @@ $body->template = '{"id":"$mtId","status":"$statusCode"}';
3690
$result = $webhooks->createWebhook($body);
3791
```
3892

39-
### πŸ“₯ Retrieve all webhooks
93+
### Retrieve all webhooks
4094
```php
4195
<?php
4296
require_once('vendor/autoload.php');
@@ -55,7 +109,7 @@ $result = $webhooks->retrieveWebhook($page, $pageSize);
55109
print_r($result);
56110
```
57111

58-
### πŸ”„ Update a webhook
112+
### Update a webhook
59113
You can get a webhook ID by looking at the `id` of each webhook created from the response of the above example.
60114
```php
61115
<?php
@@ -82,7 +136,7 @@ $body->template = '{"id":"$mtId","status":"$statusCode"}';
82136
$result = $webhooks->updateWebhook($webhookId, $body);
83137
```
84138

85-
### ❌ Delete a webhook
139+
### Delete a webhook
86140
You can get a webhook ID by looking at the `id` of each webhook created from the response of the retrieve webhooks example.
87141
```php
88142
<?php
@@ -100,11 +154,11 @@ $webhookId = "YOUR_WEBHOOK_ID";
100154
$webhooks->deleteWebhook($webhookId);
101155
```
102156

103-
## πŸ“• Documentation
104-
Check out the [full API documentation](DOCUMENTATION.md) for more detailed information.
157+
## :closed_book: API Reference Documentation
158+
Check out the [full API documentation](https://developers.messagemedia.com/code/webhooks-api-documentation/) for more detailed information.
105159

106-
## πŸ˜• Need help?
160+
## :confused: Need help?
107161
Please contact developer support at [email protected] or check out the developer portal at [developers.messagemedia.com](https://developers.messagemedia.com/)
108162

109-
## πŸ“ƒ License
163+
## :page_with_curl: License
110164
Apache License. See the [LICENSE](LICENSE) file.

0 commit comments

Comments
Β (0)