-
Notifications
You must be signed in to change notification settings - Fork 63
Create Letter endpoint
Glenn Piludu edited this page Aug 13, 2022
·
6 revisions
Create a new letter and specify a letter template. Amplify does not store this information; this API leverages the Lob createLetter API
POST /api/createLetter
Request body parameters
Name | Type | Description |
---|---|---|
description | string | A description that uniquely identifies this letter. Must be no longer than 255 characters. |
to | object | parameters below |
from | object | parameters below |
templateId | string | The Lob template_id created for this letter. |
sessionId | string | Stripe session id returned from checkout session redirect or from Stripe API. |
to
is an address object with the following parameters. This address will be verified, recorded, and assigned an ID, if possible, when submitted.
{
name: 'Amy',
address_line1: 'Address line 1',
address_line2: 'Address line 2',
address_city: 'San Francisco',
address_state: 'CA',
address_zip: '94101'
}
from
: is an object with the following parameter, which is an integer.
{
address_id: The `address_id` returned from the `createAddress` endpoint
}
- Home
- App Logic
- App Structure
- Getting Started
- Local Environment Setup
- Interacting with the Development Database
- User Background
- Features
- Data Structures
- API Quick Reference
- Single Campaign Mode (Beta)
- Front-end
- Components
- Pages
- State Management
- Amplify API reference (Database)
- Lob Mailing API integration
- Auth0 API Integration
- Stripe API integration
- Cicero API Integration
- Twilio API Integration