-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CMB-586: add booklets CRUD documentation #498
Merged
Merged
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
9846bc4
CMB-645: add list, get and delete endpoints for snap packs (#495)
sachinmurali b7a1b81
booklet create
sachinmurali fc68256
add code samples for create; start on get
sachinmurali 91185cb
get and delete endpoints
sachinmurali 2f89c9f
remove color; update campaign_id verbiage
sachinmurali 331ab53
remove color from the response examples
sachinmurali File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
description: >- | ||
Notes: | ||
|
||
- HTML merge variables should not include delimiting whitespace. | ||
|
||
- All pages of a supplied PDF file must be sized per the `size` attribute, | ||
while supplied HTML will be rendered and trimmed to as many `size` pages | ||
as necessary. | ||
|
||
- For design specifications, please see our | ||
<a href="https://s3-us-west-2.amazonaws.com/public.lob.com/assets/templates/letter_template.pdf" target="_blank">PDF</a> | ||
and [HTML](#section/HTML-Examples) templates. | ||
|
||
See <a href="https://lob.com/pricing/print-mail#compare" target="_blank">pricing</a> for extra costs incurred. | ||
|
||
oneOf: | ||
- $ref: "../../../shared/attributes/html_string.yml" | ||
- $ref: "../../../shared/attributes/model_ids/tmpl_id.yml" | ||
- $ref: "../../../shared/attributes/remote_file_url.yml" | ||
- type: string | ||
pattern: "^(?!https://)[a-zA-Z0-9@:%._+~#=/]{1,256}.(html?|pdf)$" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
type: string | ||
|
||
description: Unique identifier prefixed with `ord_`. | ||
|
||
pattern: "^ord_[0-9a-f]{26}$" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
type: string | ||
|
||
enum: | ||
- 9x6 | ||
- 8.375x5.375 | ||
|
||
description: > | ||
Specifies the size of the booklet. | ||
|
||
default: 9x6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
description: The use type for each mailpiece. Can be one of marketing, operational, or null. Null use_type is only allowed if an account default use_type is selected in Account Settings. For more information on use_type, see our [Help Center article](https://help.lob.com/print-and-mail/building-a-mail-strategy/managing-mail-settings/declaring-mail-use-type). | ||
type: string | ||
enum: | ||
- marketing | ||
- operational | ||
- null | ||
nullable: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
type: boolean | ||
description: >- | ||
Booklets are always printed in color. | ||
default: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
parameters: | ||
- in: path | ||
name: booklet_id | ||
description: id of the booklet | ||
required: true | ||
schema: | ||
$ref: "attributes/booklet_id.yml" | ||
|
||
get: | ||
operationId: booklet_retrieve | ||
|
||
summary: Retrieve | ||
|
||
description: >- | ||
Retrieves the details of an existing booklet. You need to only supply | ||
the unique booklet identifier that was returned upon booklet creation. | ||
|
||
tags: | ||
- Booklets | ||
|
||
responses: | ||
"200": | ||
description: Returns a booklet object | ||
content: | ||
$ref: responses/booklet.yml | ||
|
||
default: | ||
$ref: "../../shared/responses/mailpiece_error.yml" | ||
|
||
delete: | ||
operationId: booklet_delete | ||
|
||
summary: Delete | ||
|
||
description: >- | ||
Completely removes a booklet from production. This can only be done if the booklet's | ||
`send_date` has not yet passed. If the booklet is successfully canceled, you will not | ||
be charged for it. | ||
|
||
tags: | ||
- Booklets | ||
|
||
responses: | ||
"200": | ||
$ref: "../../shared/responses/booklet_deleted.yml" | ||
|
||
default: | ||
$ref: "../../shared/responses/mailpiece_error.yml" |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
color shouldn't be part of the booklet payload so we can remove this attribute and remove color from the samples. I think we still have it in the booklet serializer but currently it will always be undefined. I'll create a ticket to remove color and return_address.