View as Markdown
Click2Mail icon

Click2Mail ACTION

Create Job

Creates a new new job in your account. See the documentation.
  • Action
  • Writes data
  • API key
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's Click2Mail account once, then configure and run Create Job from your backend or agent.

import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "click2mail2-create-job",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    click2mail2: { authProvisionId: "apn_xxxxxxx" },
    documentClass: "Document Class",
    layout: "Layout",
  },
})

console.log(result)

SCHEMA

Inputs

Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.

Create Job inputs
Property Type Description
documentClass Document Class string
The general type of the document.
Required
layout Layout string
The specific type of the product
Required
envelope Envelope string
If this is an enveloped product this determines the envelope in which the product is to be mailed; otherwise provide no value.
Required
color Color string
Print in color or black and white.
Required
paperType Paper Type string
Sets the paper the mailing is to be printed on.
Required
printOption Print Option string
Sets simplex or duplex printing.
Required
documentId Document Id string
ID of the document to print
Optional Dynamic
addressId Address Id string
This required if the product required a recipient address list.
Optional Dynamic
rtnName RTN Name string
Return address Name.
Optional
rtnOrganization RTN Organization string
Return address Organization.
Optional
rtnaddress1 RTN Address1 string
Return address line 1.
Optional
rtnaddress2 RTN Address2 string
Return address line 2.
Optional
rtnCity RTN City string
Return address City.
Optional
rtnState RTN State string
Return address State.
Optional
rtnZip RTN Zip string
Return address Zip.
Optional
mailClass Mail Class string
Overrides the default of First Class for mailed products.
Optional
appSignature APP Signature string
This is a short signature to identify orders that come from your app.
Optional
projectId Project Id integer
Use to place this job in a pre-existing project in your account
Optional Dynamic
mailingDate Mailing Date string
Used to schedule the mailing date in the future. Format YYYYMMDD. If not provided the order will be mailed on the next available on the next business day. The business day cut off is 8PM EST.
Optional
quantity Quantity string
For products that do not use mailing lists. Quantity to print.
Optional
jobDocumentId Job Document Id string
Document ID of the job version of the document.
Optional Dynamic
jobAddressId Job Address Id string
Address List Id of the job version.
Optional
businessReplyAddressId Business Reply Address Id integer
If you are mailing a business reply mail product use this to specify the business reply address and permit information already in your account.
Optional
courtesyReplyAddressId Courtesy Reply Address Id integer
If you are mailing a courtesy reply mail product use this to specify a courtesy reply address already in your account.
Optional
returnAddressId Return Address Id integer
You may use the return address id to specify a return address already in your account.
Optional

REFERENCE

Tool details

Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.

Registry key
click2mail2-create-job
Version
0.0.3
App
Click2Mail
Authentication
API key
Read-only
No
Destructive
No
Open world
Yes