Skip to content

Commit 954a255

Browse files
committed
Add 'headers' parameter to generateRequestDetails description
1 parent 4c0864b commit 954a255

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ request only. This overrides any API key set via `setGCMAPIKey()`.
177177
- **vapidDetails** should be an object with *subject*, *publicKey* and
178178
*privateKey* values defined. These values should follow the [VAPID Spec](https://tools.ietf.org/html/draft-thomson-webpush-vapid).
179179
- **TTL** is a value in seconds that describes how long a push message is
180-
retained by the push service (by default, four weeks);
180+
retained by the push service (by default, four weeks).
181181
- **headers** is an object with all the extra headers you want to add to the request.
182182

183183
### Returns
@@ -340,7 +340,10 @@ const options = {
340340
publicKey: '< URL Safe Base64 Encoded Public Key >',
341341
privateKey: '< URL Safe Base64 Encoded Private Key >',
342342
}
343-
TTL: <Number>
343+
TTL: <Number>,
344+
headers: {
345+
'< header name >': '< header value >'
346+
}
344347
}
345348

346349
try {
@@ -391,7 +394,8 @@ request only. This overrides any API key set via `setGCMAPIKey()`.
391394
- **vapidDetails** should be an object with *subject*, *publicKey* and
392395
*privateKey* values defined. These values should follow the [VAPID Spec](https://tools.ietf.org/html/draft-thomson-webpush-vapid).
393396
- **TTL** is a value in seconds that describes how long a push message is
394-
retained by the push service (by default, four weeks);
397+
retained by the push service (by default, four weeks).
398+
- **headers** is an object with all the extra headers you want to add to the request.
395399

396400
### Returns
397401

0 commit comments

Comments
 (0)