# Batch create a blacklist of mobile phone numbers - BatchCreateUSMSBlacklistPhone

## Overview

Batch create a blacklist of mobile phone numbers






## Definition

### Public Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Action**     | string  | Corresponding API command name, the current API is `BatchCreateUSMSBlacklistPhone`.                      | **Yes** |
| **PublicKey**  | string  | The user's public key can be obtained from [Console](https://console.scloudsg.com/uaccount/api_manage)                                             | **Yes** |
| **Signature**  | string  | User signature generated based on public key and API command, see [Signature Algorithm](/docs/api/summary/signature.md)  | **Yes** |

### Request Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Region** | string | Region. See [Region and Zone List](/docs/api/summary/regionlist) |No|
| **Zone** | string | Zone. See [Region and Zone List](/docs/api/summary/regionlist) |No|
| **ProjectId** | string | Project ID. Leave it blank for the default project. Sub-accounts must fill in. Please refer to the [GetProjectList API](/docs/api/summary/get_project_list) |**Yes**|
| **IsGlobal** | boolean | Whether the entire project is effective |**Yes**|
| **BlackList** | string | Blacklist list of mobile phone numbers, this parameter is the base64 encoding result of the json array, with no more than 1000 items at a time. Sub-item parameter description:<br />{<br />"Phone": "13900000001", mobile phone number type :string<br />"Purpose": 2, SMS type int :0- No filtering 1- Verification Code 2- Notification 3- Marketing<br />"Remark": "Test Data 001" Note type: string(maximum 256 characters)<br />}<br /><br />Remark: Note (maximum 256 characters) Example:<br />Example: Send content json array (before base64 encoding):<br />[<br />{<br />"Phone": "13900000001",<br />"Purpose": 2,<br />"Remark": "Test Data 001<br />}<br />]<br />Example: Send content json array (encoded in base64):<br />Ww0KICAgICB7DQogICAgICAiUGhvbmUiOiAiMTM5MDAwMDAwMDEiLA0KICAgICAgIlB1cnBvc2UiOiAyLA0KICAgICAgIlJlbWFyayI6ICLmtYvor5XmlbDm ja4wMDEiIA0KICAgIH0NCl0=<br />Others<br />Supported mobile phone number formats<br />The mobile phone number in parentheses, with the country code (a)xxxxx inside the parentheses<br />2. Mobile phone number axxxxxx without parentheses<br />3. Mobile phone number with a plus sign +axxxxx |**Yes**|

### Response Field

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **RetCode** | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. |**Yes**|
| **Action** | string | Operation command name. |**Yes**|
| **Message** | string | Returns an error message, providing detailed description when `RetCode` is non-zero. |No|
| **ReqUuid** | string | Request Uuid this time<br /> |**Yes**|
| **SuccessList** | array[string] | Create a list of successfully registered mobile phone numbers. |**Yes**|
| **FailedList** | array[string] | List of failed mobile phone numbers for creation |**Yes**|




## Example

### Request Example
    
```
https://api.scloudsg.com/?Action=BatchCreateUSMSBlacklistPhone
&Region=cn-zj
&Zone=cn-zj-01
&ProjectId=tHdAlChQ
&IsGlobal=true
&BlackList=Ww0KICAgICB7DQogICAgICAiUGhvbmUiOiAiMTM5MDAwMDAwMDEiLA0KICAgICAgIlB1cnBvc2UiOiAyLA0KICAgICAgIlJlbWFyayI6ICLmtYvor5XmlbDmja4wMDEiIA0KICAgIH0NCl0=
```

### Response Example
    
```json
{
  "Action": "BatchCreateUSMSBlacklistPhoneResponse",
  "FailedList": [
    "13900000003",
    "13900000004"
  ],
  "Message": "Success",
  "ReqUuid": "ezKmluyR",
  "RetCode": 0,
  "SuccessList": [
    "13900000001",
    "13900000002"
  ]
}
```





