https://github.com/nhsdigital/hello-world-auth-examples
https://github.com/nhsdigital/hello-world-auth-examples
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/nhsdigital/hello-world-auth-examples
- Owner: NHSDigital
- Created: 2022-06-29T14:31:02.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-04-10T12:44:00.000Z (9 months ago)
- Last Synced: 2025-04-10T12:51:10.662Z (9 months ago)
- Language: Java
- Size: 3.9 MB
- Stars: 9
- Watchers: 32
- Forks: 10
- Open Issues: 22
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# hello-world-auth-examples
# Overview
This repository shows you how to connect to an [application-restricted REST API](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#application-restricted-apis) using [signed JWT authentication](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation/application-restricted-restful-apis-signed-jwt-authentication) using the Java and C# programming language.
To call an application restricted API you need to tell the API who the calling application is. When using signed JWT authentication you need to authenticate your application by sending a JSON Web Token (JWT) to an authentication server, signed using your application's private key. In exchange you will receive an access token which you need to include in the API request. You can learn more about signed JWT authentication [here](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation/application-restricted-restful-apis-signed-jwt-authentication).
This tutorial will show how you can use Java or C# to generate and sign a JWT, exchange this for an access token with our authentication server and how to call our example [Hello World API](https://digital.nhs.uk/developer/api-catalogue/hello-world) using your access token.
### Java Application Restricted example
Follow [README](./application-restricted-signed-jwt-tutorials/java/README.md)
### C# Application Restricted example
Follow [README](./application-restricted-signed-jwt-tutorials/csharp/README.md)