Skip to content

Latest commit

 

History

History
54 lines (36 loc) · 1.26 KB

File metadata and controls

54 lines (36 loc) · 1.26 KB

Auth

(auth())

Overview

REST APIs for managing Authentication

Available Operations

validateApiKey

Validate the current api key.

Example Usage

package hello.world;

import dev.speakeasyapi.javaclientsdk.RyanTest;
import dev.speakeasyapi.javaclientsdk.models.operations.ValidateApiKeyResponse;
import dev.speakeasyapi.javaclientsdk.models.shared.Security;
import java.lang.Exception;

public class Application {

    public static void main(String[] args) throws Exception {

        RyanTest sdk = RyanTest.builder()
                .security(Security.builder()
                    .apiKey("<YOUR_API_KEY_HERE>")
                    .build())
            .build();

        ValidateApiKeyResponse res = sdk.auth().validateApiKey()
                .call();

        if (res.apiKeyDetails().isPresent()) {
            // handle response
        }
    }
}

Response

ValidateApiKeyResponse

Errors

Error Type Status Code Content Type
models/errors/SDKError 4XX, 5XX */*