Skip to content

hpi/authenticated_hpi_api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Authenticated API for HPI

Built on top of HPI_API and setup is largely taken from seanbreckenridge's work.

If you need an in-depth guide for how HPI_API works, I suggest going to the above repo so this repo doesn't duplicate documentation.

Installation

pip install https://github.com/hpi/authenticated_hpi_api/

Running

By default, HPI_API listens on port 5050.

auth_hpi_api server -k <public key, no headers> -i <JWT issuer>

Examples

Example uses https://github.com/madelinecameron/hpi

$ curl -H "Authorization: Bearer <jwt>" http://localhost:5050/my/eightsleep/sessions
{
  "page": 1,
  "limit": 50,
  "items": [
    {
      ...
    },
  ]
}

$ curl -H "Authorization: Bearer <bad jwt>" http://localhost:5050/my/eightsleep/sessions
{
  "error": "<error message>"
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages