Fixed Sender

The fixed sender is used by the user for fixed Mailfrom。

You can query, delete and add operation


Query added senders

URL

https://api.sendcloud.net/apiv2/sender/list

HTTP Request Method

post    get

Parameter Description

parameter type required or not description
apiUser string API_USER
apiKey string API_KEY
start int start position, [0-], defaults to 0
limit int amount, [0-100],defaults to 100

Request Example

https://api.sendcloud.net/apiv2/sender/list?apiUser=***&apiKey=***

Returned Value Example

{
    "result": true,
    "statusCode": 200,
    "message": "请求成功",
    "info": {
        "total": 9,
        "dataList": [
            {
                "id": 212,
                "categoryId": 251561,
                "receivingDomain": "all",
                "fromStatus": 1,
                "from": "",
                "mailfromStatus": 1,
                "mailfrom": "",
                "categoryName": "HuAng",
                "createTime": "2023-03-15 18:28:41",
                "updateTime": "2023-03-15 18:28:41"
            }
        ],
        "count": 1
    }
}


Add sender

URL

https://api.sendcloud.net/apiv2/sender/add

HTTP Request Method

post    get

Parameter Description

parameter type required or not description
apiUser string API_USER
apiKey string API_KEY
categoryName string 指定API_USER,all 代表所有API_USER
receivingDomain string 收件域名,比如 qq.com,163.com;多个收件域名用逗号隔开,不传参或不传值则为全部域名
fromStatus int 0(不设置),1(实际值),2(固定值),默认值1
from string 1.fromStatus=0,from 不填写

2.fromStatus=1,则实际值是传入的 from 的前缀。例如 API传入from=notice@sc.gg ,系统将使用 notice@sendingDomain作为from发信,from 不填写

3.fromStatus=2,则 from将以 固定值@sendingDomain 组成 email地址,from 为必填

mailfromStatus int 0(不设置),1(去代发),2(固定值),默认值1
mailfrom string 1.mailfromStatus=0,则 mailfrom 将以 随机串@sendingDomain 组成 email地址,maiFrom 不填写

2.mailfromStatus=1,则 mailFrom 跟随from值,可去除代发,maiFrom 不填写

3.mailfromStatus=2,则 mailFrom 将以 固定值@sendingDomain 组成 email地址,maiFrom 为必填

Tips

  1. When fromStatus=0, mailfromStatus must be 2; When fromStatus=1, mailfromStatus can be 0 or 1, 2

Request Example

https://api.sendcloud.net/apiv2/sender/add?apiUser=***&apiKey=***&domainName=qq.com&categoryName=zhouwj_test_batch&sender=111

Returned Value Example

{
    "result": true,
    "statusCode": 200,
    "message": "请求成功",
    "info": {
        "data": [
            {
                "id": 215,
                "categoryId": 0,
                "receivingDomain": "127.com",
                "fromStatus": 1,
                "from": "",
                "mailfromStatus": 2,
                "mailfrom": "xiao2",
                "categoryName": "all",
                "createTime": "2023-03-16 14:47:24",
                "updateTime": "2023-03-16 14:47:24"
            }
        ]
    }
}

Delete mailfrom prefix

URL

https://api.sendcloud.net/apiv2/sender/delete

HTTP Request Method

post    get

Parameter Description

parameter type required or not description
apiUser string yes API_USER
apiKey string yes API_KEY
id int yes sender ID

Request Example

https://api.sendcloud.net/apiv2/sender/delete?apiUser=***&apiKey=***&domainName=qq.com&categoryName=zhouwj_test_batch&sender=111

Returned Value Example

{
    "result": true,
    "statusCode": 200,
    "message": "请求成功",
    "info": {
        "count": 1
    }
}