Software Development Kit (SDK)
magiclinksdev SDKs are responsible for providing programming language specific client code to interact with the API via HTTP.
This involves handling API authentication, exposing request/response data types, and performing HTTP requests. Unsuccessful API responses should be treated as errors when returned to the caller. Ideally, clients should be able to perform JWT validation using a local cache of the JWK Set.
Official SDKs
Golang
The official Go client is in the client
package of
the open-source GitHub project.
Please see the examples/client
directory to
get started.
Generate code
This project publishes formatted API specification files in Swagger 2.0 and OpenAPI 3 formats. Please see the Specification page for more information.
Code generation projects include:
3rd Party Client SDKs
If you've made an SDK for the magiclinksdev project with documentation and are willing to maintain it, please open a GitHub issue to announce it. After a review, it may be put in this documentation section with your permission.
Currently, there are no 3rd party clients.
If you are implementing your own client, please note the default JWK Set relative path is /api/v2/jwks.json
.
Every API client needs to validate the aud
claim in the JWT. This is essential to prevent a malicious service
account from requesting a signed JWT for a different service. Every service account has at least one aud
given on creation. The iss
claims should be checked too. The iss
claim is specific to the configuration of the
magiclinksdev service, typically the URL.