Lob connects to a Nagent workspace with an API key. Once it is connected, agents can call 13 Lob actions, such as "Create Domain", "Create Link" and "Get Domain". Nothing is enabled on connect: each action is allowed one at a time, and an action with side effects runs or waits for a person according to the agent's level.
Every operation an agent can call against Lob, with input parameters and output schema.
LOB_CREATE_DOMAINTool to add a new custom domain for creating custom links. Use when you need to register a domain for short link customization.
Input parameters
The registered domain/hostname.
URL to redirect customers if a short link is broken or inactive.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_CREATE_LINKTool to create a shortened URL from a long URL using Lob's link shortening service. Use when you need to shorten a long URL either by using a custom domain or Lob's own short domain.
Input parameters
The unique path for the shortened URL. If empty, a unique path will be automatically generated.
The title of the URL.
The registered domain to be used for the short URL. Defaults to 'lob.st'.
Use metadata to store custom information for tagging and labeling back to your internal systems. Must be an object with up to 20 key-value pairs. Keys must be at most 40 characters and values must be at most 500 characters. Neither can contain the characters `"` and `\\`.
The original target URL to be shortened.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_DELETE_DOMAINTool to delete a registered domain. Use only after confirming all associated links with the domain are deleted.
Input parameters
Unique identifier for a domain.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_DELETE_LINKTool to delete a shortened link. Use when you need to remove a previously created short link from the system.
Input parameters
Unique identifier for a link.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_DELETE_UPLOADTool to delete an existing upload by its unique identifier. Use when you need to permanently remove an upload and its associated data.
Input parameters
Unique identifier of the upload to delete. Format: 'upl_' followed by alphanumeric characters (e.g., 'upl_test'). This permanently deletes the upload and its associated data.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_GET_DOMAINTool to retrieve details for a single domain from Lob. Use when you need to get configuration status, redirect links, or other metadata for a specific domain.
Input parameters
Unique identifier for a domain.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_GET_LINKTool to retrieve a single shortened link. Use when you need to fetch details about a specific link by its ID.
Input parameters
Unique identifier for a link.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_LIST_DOMAINSTool to retrieve a list of all created domains. Use when you need to view or manage custom domains configured for URL shortening. Supports pagination and filtering by configuration status.
Input parameters
A reference to a list entry used for paginating to the next set of entries. Cannot be used with 'before'.
How many results to return. Maximum of 100 results per request.
A reference to a list entry used for paginating to the previous set of entries. Cannot be used with 'after'.
Status of domain configuration.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_LIST_LINKSTool to retrieve a list of shortened links. The list is sorted by creation date, with the most recently created appearing first. Use when you need to view all links or filter by campaign or domain.
Input parameters
Cursor for pagination. Retrieve results after this cursor. Cannot be used with 'before'.
How many results to return. Default is 10.
Cursor for pagination. Retrieve results before this cursor. Cannot be used with 'after'.
Filters links by the provided domain id.
Filters resources created by the provided campaign id, prefixed with 'cmp_'. In the case of snap packs, booklets, and letters with size 'us_legal', however, the campaign id is prefixed with 'camp_' instead of 'cmp_'.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_LIST_QR_CODE_ANALYTICSTool to retrieve a list of your QR codes and their analytics data. The QR codes are returned sorted by scan date, with the most recently scanned QR codes appearing first.
Input parameters
How many results to return.
An integer that designates the offset at which to begin returning results. Defaults to 0.
Request that the response include the total count by specifying include=\["total_count"\].
Filter list of responses to only include QR codes with at least one scan event.
Filter by date created. Accepted formats are ISO-8601 date or datetime, e.g. { "gt": "2012-01-01", "lt": "2012-01-31T12:34:56Z" } where "gt" is >, "lt" is <, "gte" is ≥, and "lte" is ≤.
Filter by the resource ID.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_LIST_UPLOADSTool to list uploads from Lob. Use when you need to retrieve all uploads or filter uploads by campaign ID.
Input parameters
ID of the campaign to filter uploads by. If provided, only returns uploads associated with this campaign.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_UPDATE_LINKTool to update any properties of a shortened link. Use when you need to modify the redirect URL, title, or metadata of an existing Lob shortened link. Requires the link_id and at least the redirect_link to update.
Input parameters
The title of the URL. Useful for organizing and identifying links.
Unique identifier for the link to update. Must be a valid link ID prefixed with 'lnk_'.
Use metadata to store custom information for tagging and labeling back to your internal systems. Must be an object with up to 20 key-value pairs. Keys must be at most 40 characters and values must be at most 500 characters. Neither can contain the characters '"' and '\\'. Example: {'customer_id': 'NEWYORK2015'}. Nested objects are not supported.
The original target URL to redirect to when the shortened link is accessed.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
LOB_VALIDATE_IDENTITYTool to validate whether a given name is associated with an address. Use when you need to verify identity information by checking if a recipient name matches address records.
Input parameters
City name
State abbreviation (2 characters)
ZIP code (5 or 9 digits)
Full name of the recipient to validate against the address
Primary address line (street address)
Secondary address line (apartment, suite, etc.)
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
Agents can call 13 Lob actions on Nagent, including "Create Domain", "Create Link" and "Get Domain". Create Domain: Add a new custom domain for creating custom links. Each action is listed on this page with its input parameters and its output.
Lob connects with an API key, under your workspace's own connection. Nothing is enabled on connect: each action is allowed one at a time and can be scoped to the agents that need it.
Create Domain takes 2 required inputs: domain and error_redirect_link. It returns data, error and successful.