createM2MTokenWithHttpInfo method
Create a M2M Token
Creates a new M2M Token. Must be authenticated via a Machine Secret Key.
Note: This method returns the HTTP Response.
Parameters:
- CreateM2MTokenRequest createM2MTokenRequest (required):
Implementation
Future<http.Response> createM2MTokenWithHttpInfo(
CreateM2MTokenRequest createM2MTokenRequest,
) async {
// ignore: prefer_const_declarations
final path = r'/m2m_tokens';
// ignore: prefer_final_locals
Object? postBody = createM2MTokenRequest;
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,
);
}