mirror of
https://github.com/GSA/notifications-api.git
synced 2026-08-12 18:08:05 -04:00
Add external API for sending SMS to openapi
This commit is contained in:
@@ -11,18 +11,28 @@ An API key can be created at https://notifications-admin.app.cloud.gov/services/
|
||||
|
||||
## Using OpenAPI documentation
|
||||
|
||||
### Retrieving a bearer token for use
|
||||
### Retrieving a jwt-encoded bearer token for use
|
||||
|
||||
On a mac, run
|
||||
|
||||
#### Admin UI token
|
||||
|
||||
```
|
||||
flask command create-admin-jwt | tail -n 1 | pbcopy
|
||||
```
|
||||
|
||||
#### User token
|
||||
|
||||
```
|
||||
flask command create-user-jwt --token=<USER_API_TOKEN> | tail -n 1 | pbcopy
|
||||
```
|
||||
|
||||
to copy a token usable by the admin UI to your pasteboard. This token will expire in 30 seconds
|
||||
|
||||
### Disable token expiration checking in development
|
||||
|
||||
Because jwt tokens expire so quickly, the development server can be set to allow tokens older than 30 seconds:
|
||||
|
||||
```
|
||||
env ALLOW_EXPIRED_API_TOKEN=1 make run-flask
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user