---
title: "Preview an SMS message for a membership"
method: POST
path: "/shop/memberships/{membershipId}/sms/preview"
tags: ["Memberships"]
---

# Preview an SMS message for a membership

`POST /shop/memberships/{membershipId}/sms/preview`

This endpoint previews an SMS message for a membership.

## Request body

- object
  - `message_type` 'billing_details_request', required — The type of the SMS message.
  - `always_send` boolean — If true, preview the SMS even if the membership already has a payment method. Defaults to false.

## Response `200`

The preview of the SMS message was successfully retrieved

- object
  - `data` MembershipSmsMessagePreview, required
    - `message` string, required — The contents of the SMS message.
    - `site_id` string, uuid, required — The ID of the site the SMS message is associated with.
    - `organisation_id` string, uuid, required — The ID of the organisation the SMS message is associated with.

## Other responses

- `401` — The user is unauthenticated
- `403` — The authenticated user does not have permission.
- `404` — The resource couldn't be found
- `422` — The request didn't pass validation

---

[API](https://skmtc.dev/try/apis/trybe-api.md) · [All operations](https://skmtc.dev/try/apis/trybe-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/try/trybe-api/revisions/f37f92702da5/schema)
