# Search SMS Newsletters

Lists the SMS newsletters of the account -- one-off SMS campaigns --, optionally filtered by name and state, ordered by ID and paged with a cursor. Email newsletters are search-newsletters, SMS follow-ups search-autoresponders. Reads only.

## Input schema:

```json
{
  "type": "object",
  "properties": {
    "query": {
      "type": [
        "null",
        "string"
      ],
      "description": "Part of the name, case-insensitive; omit for all",
      "default": null,
      "maxLength": 250
    },
    "status": {
      "type": [
        "null",
        "string"
      ],
      "description": "Only SMS newsletters in this state: draft, scheduled, outgoing or sent",
      "default": null,
      "enum": [
        "draft",
        "scheduled",
        "outgoing",
        "sent"
      ]
    },
    "cursor": {
      "type": [
        "null",
        "string"
      ],
      "description": "nextCursor of the previous page; omit for the first page",
      "default": null,
      "maxLength": 200
    },
    "pageSize": {
      "type": "integer",
      "description": "SMS newsletters per page, 1 to 100",
      "default": 25,
      "minimum": 1,
      "maximum": 100
    },
    "accountId": {
      "type": [
        "null",
        "integer"
      ],
      "description": "User ID of the account; omit for the account of the access token",
      "default": null,
      "minimum": 1
    }
  },
  "additionalProperties": false
}
```

## Output schema:

```json
{
  "type": "object",
  "required": [
    "accountId",
    "count",
    "hasNextPage",
    "nextCursor",
    "newsletters"
  ],
  "properties": {
    "accountId": {
      "type": "integer"
    },
    "count": {
      "type": "integer"
    },
    "hasNextPage": {
      "type": "boolean"
    },
    "nextCursor": {
      "type": [
        "string",
        "null"
      ]
    },
    "newsletters": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "newsletterId",
          "name",
          "status",
          "smsId",
          "isSplitTest",
          "sendAt",
          "sent",
          "editUrl",
          "statisticsUrl"
        ],
        "properties": {
          "newsletterId": {
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "draft",
              "scheduled",
              "outgoing",
              "sent"
            ]
          },
          "smsId": {
            "type": [
              "integer",
              "null"
            ]
          },
          "isSplitTest": {
            "type": "boolean"
          },
          "sendAt": {
            "type": [
              "string",
              "null"
            ]
          },
          "sent": {
            "type": "integer"
          },
          "editUrl": {
            "type": "string"
          },
          "statisticsUrl": {
            "type": "string"
          }
        }
      }
    }
  }
}
```

