Skip to content

Commit

Permalink
Merge pull request #78 from tjacovich/api-gateway-edits
Browse files Browse the repository at this point in the history
Api gateway edits
  • Loading branch information
tjacovich authored Dec 20, 2024
2 parents f8916f7 + 92aa675 commit eea8047
Show file tree
Hide file tree
Showing 5 changed files with 68 additions and 68 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,28 +85,28 @@ curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" "htt
* To save user-data (i.e. preferences)

```$bash
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-Adsws-Uid: 1" "http://localhost:5000/user-data" -X POST -d $'{"foo": "bar"}'
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-api-uid: 1" "http://localhost:5000/user-data" -X POST -d $'{"foo": "bar"}'
```

note: The X-Adsws-Uid header *must* be present (normally, it is set by the API gateway)
note: The X-api-uid header *must* be present (normally, it is set by the API gateway)


* To get the user-data:

```$bash
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-Adsws-Uid: 1" "http://localhost:5000/user-data" -X GET
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-api-uid: 1" "http://localhost:5000/user-data" -X GET
```

### /configuration

* Retrieve Bumblebee configuration (values that can be used to customize user experience)

```$bash
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-Adsws-Uid: 1" "http://localhost:5000/configuration" -X GET
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-api-uid: 1" "http://localhost:5000/configuration" -X GET
{"foo": "bar"}
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-Adsws-Uid: 1" "http://localhost:5000/configuration/foo" -X GET
curl -H "Content-Type: application/json" -H "Authorization: Bearer <TOKEN>" -H "X-api-uid: 1" "http://localhost:5000/configuration/foo" -X GET
"bar"
```
Loading

0 comments on commit eea8047

Please sign in to comment.