# ACMEProviderAccountService
> ACME服务商账号

---

## countAllEnabledACMEProviderAccounts
> 计算所有服务商账号数量

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/countAllEnabledACMEProviderAccounts`
- RPC：`rpc countAllEnabledACMEProviderAccounts(CountAllEnabledACMEProviderAccountsRequest) returns (RPCCountResponse);`

**请求对象 (`CountAllEnabledACMEProviderAccountsRequest`)**

```json
{}
```

**响应对象 (`RPCCountResponse`)**

```json
{
  "count": "int64 // 数量"
}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/countAllEnabledACMEProviderAccounts" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## createACMEProviderAccount
> 创建服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/createACMEProviderAccount`
- RPC：`rpc createACMEProviderAccount(CreateACMEProviderAccountRequest) returns (CreateACMEProviderAccountResponse);`

**请求对象 (`CreateACMEProviderAccountRequest`)**

```json
{
  "name": "string // 名称",
  "providerCode": "string",
  "eabKid": "string",
  "eabKey": "string"
}
```

**响应对象 (`CreateACMEProviderAccountResponse`)**

```json
{
  "acmeProviderAccountId": "int64"
}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/createACMEProviderAccount" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## deleteACMEProviderAccount
> 删除服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/deleteACMEProviderAccount`
- RPC：`rpc deleteACMEProviderAccount(DeleteACMEProviderAccountRequest) returns (RPCSuccess);`

**请求对象 (`DeleteACMEProviderAccountRequest`)**

```json
{
  "acmeProviderAccountId": "int64"
}
```

**响应对象 (`RPCSuccess`)**

```json
{}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/deleteACMEProviderAccount" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## findAllACMEProviderAccountsWithProviderCode
> 使用代号查找服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/findAllACMEProviderAccountsWithProviderCode`
- RPC：`rpc findAllACMEProviderAccountsWithProviderCode(FindAllACMEProviderAccountsWithProviderCodeRequest) returns (FindAllACMEProviderAccountsWithProviderCodeResponse);`

**请求对象 (`FindAllACMEProviderAccountsWithProviderCodeRequest`)**

```json
{
  "acmeProviderCode": "string"
}
```

**响应对象 (`FindAllACMEProviderAccountsWithProviderCodeResponse`)**

```json
{
  "acmeProviderAccounts": "[]ACMEProviderAccount"
}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/findAllACMEProviderAccountsWithProviderCode" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## findEnabledACMEProviderAccount
> 查找单个服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/findEnabledACMEProviderAccount`
- RPC：`rpc findEnabledACMEProviderAccount(FindEnabledACMEProviderAccountRequest) returns (FindEnabledACMEProviderAccountResponse);`

**请求对象 (`FindEnabledACMEProviderAccountRequest`)**

```json
{
  "acmeProviderAccountId": "int64"
}
```

**响应对象 (`FindEnabledACMEProviderAccountResponse`)**

```json
{
  "acmeProviderAccount": "ACMEProviderAccount"
}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/findEnabledACMEProviderAccount" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## listEnabledACMEProviderAccounts
> 列出单页服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/listEnabledACMEProviderAccounts`
- RPC：`rpc listEnabledACMEProviderAccounts(ListEnabledACMEProviderAccountsRequest) returns (ListEnabledACMEProviderAccountsResponse);`

**请求对象 (`ListEnabledACMEProviderAccountsRequest`)**

```json
{
  "offset": "int64 // 读取位置",
  "size": "int64 // 数量，通常不能小于0"
}
```

**响应对象 (`ListEnabledACMEProviderAccountsResponse`)**

```json
{
  "acmeProviderAccounts": "[]ACMEProviderAccount"
}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/listEnabledACMEProviderAccounts" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---

## updateACMEProviderAccount
> 修改服务商账号

- 角色：`admin`
- HTTP：`POST https://backend.dooki.cloud/ACMEProviderAccountService/updateACMEProviderAccount`
- RPC：`rpc updateACMEProviderAccount(UpdateACMEProviderAccountRequest) returns (RPCSuccess);`

**请求对象 (`UpdateACMEProviderAccountRequest`)**

```json
{
  "acmeProviderAccountId": "int64",
  "name": "string // 名称",
  "eabKid": "string",
  "eabKey": "string"
}
```

**响应对象 (`RPCSuccess`)**

```json
{}
```

**调用示例**

```bash
curl -X POST "https://backend.dooki.cloud/ACMEProviderAccountService/updateACMEProviderAccount" \
  -H "Content-Type: application/json" \
  -H "X-Edge-Access-Token: <YOUR_TOKEN>" \
  -d '{
    ...
  }'
```

---
