All URIs are relative to https://api.authlete.com
Method | HTTP request | Description |
---|---|---|
AuthTokenApi | Post /api/auth/token | /api/auth/token API |
AuthTokenFailApi | Post /api/auth/token/fail | /api/auth/token/fail API |
AuthTokenIssueApi | Post /api/auth/token/issue | /api/auth/token/issue API |
TokenResponse AuthTokenApi(ctx).TokenRequest(tokenRequest).Execute()
/api/auth/token API
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
tokenRequest := *openapiclient.NewTokenRequest("Parameters_example") // TokenRequest |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TokenEndpointApi.AuthTokenApi(context.Background()).TokenRequest(tokenRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TokenEndpointApi.AuthTokenApi``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `AuthTokenApi`: TokenResponse
fmt.Fprintf(os.Stdout, "Response from `TokenEndpointApi.AuthTokenApi`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiAuthTokenApiRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
tokenRequest | TokenRequest |
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TokenFailResponse AuthTokenFailApi(ctx).TokenFailRequest(tokenFailRequest).Execute()
/api/auth/token/fail API
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
tokenFailRequest := *openapiclient.NewTokenFailRequest("Ticket_example", "Reason_example") // TokenFailRequest |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TokenEndpointApi.AuthTokenFailApi(context.Background()).TokenFailRequest(tokenFailRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TokenEndpointApi.AuthTokenFailApi``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `AuthTokenFailApi`: TokenFailResponse
fmt.Fprintf(os.Stdout, "Response from `TokenEndpointApi.AuthTokenFailApi`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiAuthTokenFailApiRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
tokenFailRequest | TokenFailRequest |
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TokenIssueResponse AuthTokenIssueApi(ctx).TokenIssueRequest(tokenIssueRequest).Execute()
/api/auth/token/issue API
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
tokenIssueRequest := *openapiclient.NewTokenIssueRequest("Ticket_example", "Subject_example") // TokenIssueRequest |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.TokenEndpointApi.AuthTokenIssueApi(context.Background()).TokenIssueRequest(tokenIssueRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `TokenEndpointApi.AuthTokenIssueApi``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `AuthTokenIssueApi`: TokenIssueResponse
fmt.Fprintf(os.Stdout, "Response from `TokenEndpointApi.AuthTokenIssueApi`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiAuthTokenIssueApiRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
tokenIssueRequest | TokenIssueRequest |
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]