/* tslint:disable */ /* eslint-disable */ /** * HashiCorp Vault API * HTTP API that gives you full access to Vault. All API routes are prefixed with `/v1/`. * * The version of the OpenAPI document: 1.21.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ /** * Check if a given object implements the ConsulWriteRoleRequest interface. */ export function instanceOfConsulWriteRoleRequest(value) { return true; } export function ConsulWriteRoleRequestFromJSON(json) { return ConsulWriteRoleRequestFromJSONTyped(json, false); } export function ConsulWriteRoleRequestFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'consulNamespace': json['consul_namespace'] == null ? undefined : json['consul_namespace'], 'consulPolicies': json['consul_policies'] == null ? undefined : json['consul_policies'], 'consulRoles': json['consul_roles'] == null ? undefined : json['consul_roles'], 'lease': json['lease'] == null ? undefined : json['lease'], 'local': json['local'] == null ? undefined : json['local'], 'maxTtl': json['max_ttl'] == null ? undefined : json['max_ttl'], 'nodeIdentities': json['node_identities'] == null ? undefined : json['node_identities'], 'partition': json['partition'] == null ? undefined : json['partition'], 'policies': json['policies'] == null ? undefined : json['policies'], 'policy': json['policy'] == null ? undefined : json['policy'], 'serviceIdentities': json['service_identities'] == null ? undefined : json['service_identities'], 'tokenType': json['token_type'] == null ? undefined : json['token_type'], 'ttl': json['ttl'] == null ? undefined : json['ttl'], }; } export function ConsulWriteRoleRequestToJSON(json) { return ConsulWriteRoleRequestToJSONTyped(json, false); } export function ConsulWriteRoleRequestToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'consul_namespace': value['consulNamespace'], 'consul_policies': value['consulPolicies'], 'consul_roles': value['consulRoles'], 'lease': value['lease'], 'local': value['local'], 'max_ttl': value['maxTtl'], 'node_identities': value['nodeIdentities'], 'partition': value['partition'], 'policies': value['policies'], 'policy': value['policy'], 'service_identities': value['serviceIdentities'], 'token_type': value['tokenType'], 'ttl': value['ttl'], }; }