apiV1ApiKeysPostWithHttpInfo method

Future<Response> apiV1ApiKeysPostWithHttpInfo({
  1. CreateApiKey? createApiKey,
})

Create API key

Create a new API key (key is only shown once)

Note: This method returns the HTTP Response.

Parameters:

Implementation

Future<Response> apiV1ApiKeysPostWithHttpInfo({ CreateApiKey? createApiKey, }) async {
  // ignore: prefer_const_declarations
  final path = r'/api/v1/api-keys';

  // ignore: prefer_final_locals
  Object? postBody = createApiKey;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  const contentTypes = <String>['application/json'];


  return apiClient.invokeAPI(
    path,
    'POST',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
  );
}