createLicenseWithHttpInfo method

Future<Response> createLicenseWithHttpInfo(
  1. String account,
  2. CreateLicenseRequest createLicenseRequest
)

Create a license

Creates a new license resource.

Note: This method returns the HTTP Response.

Parameters:

  • String account (required): The identifier (UUID) or slug of your Keygen account.

  • CreateLicenseRequest createLicenseRequest (required):

Implementation

Future<Response> createLicenseWithHttpInfo(String account, CreateLicenseRequest createLicenseRequest,) async {
  // ignore: prefer_const_declarations
  final path = r'/accounts/{account}/licenses'
    .replaceAll('{account}', account);

  // ignore: prefer_final_locals
  Object? postBody = createLicenseRequest;

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

  const contentTypes = <String>['application/vnd.api+json'];


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