Create new targets
PUT
/accounts/{account_id}/infrastructure/targets/batch https://api.cloudflare.com/client/v4
Adds one or more targets.
Parameters
path Path Parameters
| Name | Type |
|---|---|
account_id
required
| type InfraAccountTag = string |
Request Body
application/json
required
{ hostname: string;ip: InfraIPInfo ; }[]
Responses
200 application/json
Successfully created the targets
type InfraApiResponseSingle = interface InfraApiResponseCommon {
errors:InfraMessages ;
messages:InfraMessages ;
success: true;
} & {} & { result?:InfraTargetArray ; }
errors:
messages:
success: true;
} & {} & { result?:
Client Errors
4XX application/json
Failed to create the targets
interface InfraApiResponseCommonFailure {
errors:InfraMessages ;
messages:InfraMessages ;
result: null;
success: false;
}
errors:
messages:
result: null;
success: false;
}