Manage Linkedin Invite Queue
manage_linkedin_invite_queueBulk operations (status, approve-all, cancel_all) act on the current agent's queue when run inside an agent, and across the whole account from account-level chat — except a bulk cancel_all or approve-all, which from account-level chat is rejected unless agent_id names the campaign, so it can't hit every campaign at once. Targeting one person by target_provider_id reaches them in any agent. Pacing / next_scheduled / daily usage stay account-wide (the LinkedIn rate limit is per-account). Dict with action result and current queue status
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| action | Yes | One of: - 'status': Get full queue details (pending/sent/failed items with names and times). The `pending_items` / `pending_approval_items` / `failed_items` lists cap at 50 each, each with a matching `*_truncated` flag — when a list's flag is True, more rows exist past this page; pass `offset` (offset += 50) to read them. Each `failed_items` row carries `last_error`, the reason that send failed — read it to answer "why wasn't X sent?". `pending_approval_items` rows also carry `last_error` when the row was held for a reason beyond plain approval gating (e.g. the resolver's name-mismatch hold). Queued post comments and reactions carry `post_url` and a `post_text` excerpt of the post the action targets, so you can tell which post a queued comment is on; `post_text_truncated` True means the target post ran longer than the excerpt shown. All four lists share one field shape; a `resolving_items` row (profile not yet resolved) has a blank `target_provider_id` and its `message` is the copy that will send once it resolves — edit or cancel it by its `target_identifier`. Every `pending_items` / `resolving_items` row carries `projected_send_day` + `projected_send_time` (a resolving row's is its projected lookup time, or its projected send time once it's a resolve-then-send) and a `queue_position` — the row's place in the one ordered lookup+send timeline, so the two lists interleave into what actually fires next. The top-level `cancelled_by_kind` maps each cancel cause to its count (`recipient_replied`, `task_deleted`, `auto_shelved`, …; pre-taxonomy rows under `unknown`) — read it to answer "how much outreach was cancelled, and why?". - 'update': Update a queued item's message text. Name the item by target_provider_id (a pending row's pid) OR, for a resolving row that has no pid yet, by target_identifier (its URL/slug, shown on the row). Use this to edit a queued message — including on resolving rows, which still hold the message that will send once their profile resolves. When a target has more than one queued action — a post with both a comment and a reaction, or a person with a connection request and a follow — also pass action_type to name which one to edit. - 'approve': Send authorization belongs to the user, so this action needs a message that arrived after the drafts were queued and explicitly says to approve or send them. A message from before the drafts existed cannot authorize them — a request to review them, to approve them later, or to be able to approve from chat means: report that the queue is awaiting approval and end your turn; the user's next message decides. Once authorized, this moves pending_approval items to 'pending'; they then send in queue order at your account's pace. If target_provider_id is given, approve only that item. Otherwise approve ALL pending_approval items (optionally filtered by action_type). Only touches items already awaiting approval — it does NOT run pending profile lookups or pre-approve resolving rows (those aren't in the approvals UI, so nobody has reviewed them; they resolve on their own schedule and, if the user's settings gate the action, surface for approval once resolved). From account-level chat an approve-all is rejected unless agent_id names the campaign — it must not fire every campaign's drafts into sending at once. - 'cancel': Cancel a queued item. Pass target_provider_id to cancel that one person or post — every queued action for them — or target_identifier to cancel a resolving row that has no pid yet. To cancel the ENTIRE pending queue — which drops drafts the user already approved — you must pass cancel_all=True; an unscoped cancel without it is rejected (an action_type or node_id filter alone is still a bulk cancel and also needs cancel_all=True). Narrow a cancel_all to one flow stage with node_id (e.g. restart only the m2 messages without touching m3) — the only way to separate two stages that share an action_type. From account-level chat a cancel_all is rejected unless agent_id names the campaign to cancel — it must not clear every campaign's queue at once. - 'pause': Pause the queue (stops sending, keeps items queued). Pass resume_at to schedule an automatic resume ("pause while I'm on vacation, resume July 20"); without it the pause is indefinite and only an explicit 'resume' restarts sending. - 'resume': Resume the queue (pending items drain in queue order at your account's pace) | |
| offset | No | For 'status' only — skip this many items in each queued list before returning the next 50. Use it to page through a queue larger than 50 (offset=50 for items 51-100, etc.). | |
| message | No | For 'update' — new message text. 300 chars max for connection requests. | |
| node_id | No | For 'cancel' only — narrow a cancel_all to the queue rows on one flow node (the row's flow stage, e.g. 'm1', 'm2'), parallel to action_type. action_type is the send mechanism (connection_request / message / inmail / ...), not the stage, so every message stage shares action_type='message' — node_id is the only handle that isolates one (m1 and m2 are both action_type='message', so only node_id restarts m1 without touching m2). Still a bulk cancel — needs cancel_all=True, not a substitute for it. | |
| agent_id | No | For 'cancel' and 'approve' — scope a bulk cancel_all / approve-all to one campaign's queue. Required from account-level chat (no active agent), where an unscoped bulk cancel or approve is rejected; call list_agents to get the id. | |
| resume_at | No | For 'pause' — ISO datetime when sending should automatically resume. Must be in the future. A naive datetime is interpreted in the user's timezone. Use resolve_date first for natural language ("July 20", "in 2 weeks"). | |
| cancel_all | No | For 'cancel' only — confirm a queue-wide cancel when no target_provider_id is given. Guards against silently tearing down the whole campaign. | |
| action_type | No | The kind of queued action to target, as shown on each queue row in the 'status' result (e.g. 'comment', 'reaction', 'connection_request', 'follow'). For 'update', pass it when a target carries more than one queued action so the right row is chosen. For 'approve' and 'cancel', it narrows the bulk operation to one kind — a bare target_provider_id on 'cancel' cancels every queued action for that person or post. Not a substitute for cancel_all. | |
| as_teammate | No | Act on a consented teammate's queue instead of your own — pass their email. Covers approve / cancel / update / status; pause and resume (account-wide controls) are not available on a teammate's behalf. A bulk approve-all / cancel_all must name one of the teammate's campaigns via agent_id. Gated on that teammate's act-on-behalf setting; a teammate who hasn't granted it is rejected. Omit for your own. | |
| target_identifier | No | For 'update' and 'cancel' of a resolving row (profile not yet resolved, blank target_provider_id) — the row's URL/slug, shown on the row in the 'status' result. Ignored when target_provider_id is set. | |
| target_provider_id | No | For 'update' and 'cancel' — the person's pid or post URN to target. A resolving row has no pid yet — target it by target_identifier instead. For 'cancel', leave empty (with cancel_all=True) to cancel all pending items. |