UNPKG

@pipedream/lob

Version:

Pipedream Lob Components

24 lines (23 loc) 737 B
import { defineAction } from "@pipedream/types"; import lob from "../../app/lob.app.mjs"; export default defineAction({ key: "lob-retrieve-postcard", name: "Retrieve Postcard", description: "Retrieves the details of an existing postcard. [See docs here](https://docs.lob.com/#tag/Postcards/operation/postcard_retrieve).", version: "0.0.2", type: "action", props: { lob, postcardId: { propDefinition: [ lob, "postcardId", ], }, }, async run({ $ }) { const response = await this.lob.retrievePostcard(this.postcardId); $.export("$summary", "Successfully retrieved postcard"); return response; }, });