Get the OpenID configuration
curl --request GET \
--url https://{issuer}/.well-known/openid-configurationimport requests
url = "https://{issuer}/.well-known/openid-configuration"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{issuer}/.well-known/openid-configuration', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{issuer}/.well-known/openid-configuration",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{issuer}/.well-known/openid-configuration"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{issuer}/.well-known/openid-configuration")
.asString();require 'uri'
require 'net/http'
url = URI("https://{issuer}/.well-known/openid-configuration")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"issuer": "https://your-app.auth.didit.me",
"authorization_endpoint": "https://your-app.auth.didit.me/sign-in",
"token_endpoint": "https://your-app.auth.didit.me/token/",
"jwks_uri": "https://your-app.auth.didit.me/.well-known/jwks.json",
"response_types_supported": [
"code"
],
"response_modes_supported": [
"query"
],
"grant_types_supported": [
"authorization_code",
"refresh_token"
],
"subject_types_supported": [
"public"
],
"id_token_signing_alg_values_supported": [
"ES256"
],
"token_endpoint_auth_methods_supported": [
"none"
],
"code_challenge_methods_supported": [
"S256"
],
"scopes_supported": [
"openid",
"email",
"phone",
"profile",
"offline_access"
],
"claims_supported": [
"iss",
"aud",
"sub",
"sid",
"auth_time",
"nonce",
"vendor_data",
"amr",
"org",
"verified",
"act",
"email",
"email_verified",
"name",
"phone_number"
]
}API reference
Get OpenID Configuration | Didit Authentication API
GET /.well-known/openid-configuration returns your application’s OpenID Connect discovery document: issuer, endpoints, grants, ES256 and claims.
GET
/
.well-known
/
openid-configuration
Get the OpenID configuration
curl --request GET \
--url https://{issuer}/.well-known/openid-configurationimport requests
url = "https://{issuer}/.well-known/openid-configuration"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{issuer}/.well-known/openid-configuration', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{issuer}/.well-known/openid-configuration",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{issuer}/.well-known/openid-configuration"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{issuer}/.well-known/openid-configuration")
.asString();require 'uri'
require 'net/http'
url = URI("https://{issuer}/.well-known/openid-configuration")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"issuer": "https://your-app.auth.didit.me",
"authorization_endpoint": "https://your-app.auth.didit.me/sign-in",
"token_endpoint": "https://your-app.auth.didit.me/token/",
"jwks_uri": "https://your-app.auth.didit.me/.well-known/jwks.json",
"response_types_supported": [
"code"
],
"response_modes_supported": [
"query"
],
"grant_types_supported": [
"authorization_code",
"refresh_token"
],
"subject_types_supported": [
"public"
],
"id_token_signing_alg_values_supported": [
"ES256"
],
"token_endpoint_auth_methods_supported": [
"none"
],
"code_challenge_methods_supported": [
"S256"
],
"scopes_supported": [
"openid",
"email",
"phone",
"profile",
"offline_access"
],
"claims_supported": [
"iss",
"aud",
"sub",
"sid",
"auth_time",
"nonce",
"vendor_data",
"amr",
"org",
"verified",
"act",
"email",
"email_verified",
"name",
"phone_number"
]
}Authentication is new. These endpoints are served by your application’s issuer, such as
https://<name>.auth.didit.me, and never take your Didit API key.Response
The discovery document.
The issuer's OpenID Connect discovery document. Read endpoints from here rather than building them.
The issuer: the application's sign-in origin, without a trailing slash. Every token's iss equals it.
Example:
"https://your-app.auth.didit.me"
The hosted sign-in page (/sign-in).
Example:
"https://your-app.auth.didit.me/sign-in"
Example:
"https://your-app.auth.didit.me/token/"
Example:
"https://your-app.auth.didit.me/.well-known/jwks.json"
Example:
["code"]
Example:
["query"]
Example:
["authorization_code", "refresh_token"]
Example:
["public"]
Example:
["ES256"]
none: clients are public and send no secret.
Example:
["none"]
Example:
["S256"]
Example:
[
"openid",
"email",
"phone",
"profile",
"offline_access"
]
Example:
[
"iss",
"aud",
"sub",
"sid",
"auth_time",
"nonce",
"vendor_data",
"amr",
"org",
"verified",
"act",
"email",
"email_verified",
"name",
"phone_number"
]