Skip to content
OperationsFacebook Marketplace

Send a Marketplace message

Sends a message with a connected Facebook account: the first one to a Marketplace listing's seller, or a reply in one of the account's Marketplace conversations. Answers the message as Facebook keeps it.

facebook_marketplace/messages/send3 credits a callv1.0.0

When to use it

You buy or sell on Facebook Marketplace with a connected account and want to write to someone: give listing (a listing's id or link, as facebook_marketplace/listings/search and listings/get return them) to send its seller a first message, or conversation (as facebook_marketplace/conversations/list returns it) to reply in a conversation the account already has, never both. The answer is the message as messages/list reads it, with the conversation's id to reply in later. Each message is sent once and never retried by lobstr.io: a call that fails sent nothing, except send_unconfirmed, after which you check the conversation with facebook_marketplace/messages/list before sending again. An account sends at most 5 messages a day here, 20 to 40 seconds apart.

It runs with one of your own Facebook Marketplace accounts, connected once: Accounts.

Try it

The options on the left write the call; the answer on the right is the contract's example. With your API key, the same call returns live data.

1Request
The message, as the person reading it will see it: plain text, line breaks kept, 2,000 characters at most.
For a first message to its seller: the listing's id, or the link of its page (facebook.com/marketplace/item/<id>), as facebook_marketplace/listings/search and listings/get give them.
3 credits a call
Code, from the fields above
curl https://api.lobstr.io/v2/run \
  -H "Authorization: Bearer $LOBSTR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "source": "facebook_marketplace",
    "operation": "messages/send",
    "options": {
      "text": "Hi! Is this still available? I can pick it up this week.",
      "listing": "1438514411597979"
    }
  }'
2Response

An example answer. Run it on your own input.

{
  "object": "run",
  "id": "run_tacrv64nwg3l6ajkspcewvmcty",
  "livemode": true,
  "source": "facebook_marketplace",
  "operation": "messages/send",
  "version": "1.0.0",
  "schema_url": "https://api.lobstr.io/v2/catalog/facebook_marketplace/messages/send",
  "options": {
    "listing": "1438514411597979",
    "text": "Hi! Is this still available? I can pick it up this week."
  },
  "fields": null,
  "status": "succeeded",
  "count": 1,
  "has_more": false,
  "next": null,
  "cost": {
    "credits": 3
  },
  "results": [
    {
      "object": "message",
      "id": "mid.$gAAXygFXndUuoYs0jrGiMYfZuPX9V",
      "position": 1,
      "conversation_id": "1674007894521163",
      "text": "Hi! Is this still available? I can pick it up this week.",
      "sent_at": "2026-12-01T12:14:59Z",
      "sender": {
        "id": "1095825462",
        "name": "Alex Morgan",
        "photo_url": "https://scontent.xx.fbcdn.net/v/t1.30497-1/84628273_176159830277856_972693363922829312_n.jpg",
        "is_account": true
      },
      "is_admin_message": false,
      "attachments": [],
      "sticker_id": null,
      "reactions": [],
      "reply_to": null,
      "mentions": [],
      "read_by_other": false,
      "is_forwarded": false,
      "is_unsent": false,
      "unsent_at": null,
      "edit_count": 0,
      "url": "https://www.facebook.com/messages/t/1674007894521163/",
      "source_url": "https://www.facebook.com/marketplace/item/1438514411597979/",
      "observed_at": "2026-12-01T12:15:00Z"
    }
  ]
}

Options

textstringrequired
The message, as the person reading it will see it: plain text, line breaks kept, 2,000 characters at most.
listingstring
For a first message to its seller: the listing's id, or the link of its page (facebook.com/marketplace/item/), as facebook_marketplace/listings/search and listings/get give them. Give it or conversation, never both.
conversationstring
For a reply: the conversation's id, or its link in Messenger (facebook.com/messages/t/), as facebook_marketplace/conversations/list gives them, or as a first message's answer says it (conversation_id). Give it or listing, never both.
accountstring
The connected Facebook account that writes (GET /v2/accounts). Left out, the platform takes the first of your Facebook accounts with a message left today and a free slot.

Record

Each record of results, in the envelope every call returns (Run an operation).

objectstring
idstring
The message's id on Facebook (mid.$...), as messages/list gives it; null when Facebook confirmed the message but its conversation did not show it yet.
positioninteger
Its rank from the latest: 1, the message just sent.
conversation_idstring
The conversation's id, as conversations/list's id.
textstring
As written; Facebook's own line for an event (Daniel sold 1 Bed 1 Bath Apartment/condo.) when is_admin_message; null for a message of photos or a sticker only.
sent_atdate
sender.idstring
Their Facebook id: facebook_marketplace/sellers/get reads a seller by it.
sender.namestring
sender.photo_urlstring
sender.is_accountboolean
Whether the connected account wrote it.
is_admin_messageboolean
Facebook's own line (a listing sold, a name changed), not a person's.
attachmentslist
Its photos, videos, voice messages and files (kind: file), and shared cards (kind: card), in order.
sticker_idstring
reactionslist
reply_to.message_idstring
reply_to.textstring
reply_to.sender_idstring
reply_to.media_urlstring
reply_to.sent_atdate
mentionslist
read_by_otherboolean
For the account's own messages: whether the person on the other side has read it (how far they read, as Messenger says). Null for their messages, or when Facebook does not say.
is_forwardedboolean
is_unsentboolean
Taken back by its sender: its text is gone.
unsent_atdate
edit_countinteger
urlstring
The conversation in Messenger.
source_urlstring
observed_atdate

Errors

Its own, besides those of every call (Errors). A failed call is free.

CodeStatusWhat it means
invalid_options422text is the message, and listing (a listing's id or link) or conversation (a conversation's id or link) says where it goes: one of the two, never both.
not_found404Facebook shows no such listing (sold and removed, deleted, or never listed), or the account has no Marketplace conversation with this id (facebook_marketplace/conversations/list gives its conversations). Nothing was sent.
cannot_message409Facebook does not let this account write to this listing's seller (the account's own listing, or one whose seller takes no messages). Nothing was sent.
conversation_exists409The account already has a conversation with this seller about this listing: reply in it with conversation (facebook_marketplace/conversations/list gives it). Nothing was sent.
message_refused422Facebook refused to send this message, in its own words below. It counts in the account's day, and the account sends nothing more here for 24 hours (retry_after), so that Facebook does not restrict it further.
send_unconfirmed502The message left, but Facebook's confirmation did not come back. It may have been sent: check the conversation with facebook_marketplace/messages/list before sending it again. Not charged.
account_required422You have no connected Facebook account. Connect one with POST /v2/accounts {"site": "facebook", "cookies": ...}: the cookies of a browser where you are logged in to facebook.com (https://docs.lobstr.io/accounts).
account_rate_limited429This Facebook account cannot send right now: it waits 20 to 40 seconds between two messages, and Facebook can slow it down. retry_after says when it can again, in seconds. Retrying before then gets this same answer: nothing is queued, and nothing was sent. Retryable.
account_quota_exceeded429Your Facebook accounts sent their 5 messages for today; retry_after says when the day starts over (midnight UTC). Nothing was sent. Retryable.
account_unusable409Facebook logged this account out or asks it a security check. Open facebook.com in the browser the account comes from, then connect it again with POST /v2/accounts and fresh cookies (the same account keeps its id). Nothing was sent.
site_unavailable503Facebook did not answer properly before the message left; nothing was sent, retry later (not charged). Retryable.
unexpected_answer424Facebook answered in a shape we do not read yet, before the message left: nothing was sent; we are told and fix it (not charged).

Price

3 credits a message sent. A message Facebook refuses, a call your account's pace or daily count holds back, and a failed call are free. What a credit costs on each plan: Credits and pricing.

Each connected account makes one call every 20 seconds, plus 0 to 20 seconds and 5 a day; a busy account answers at once with account_rate_limited and retry_after.

Changelog

1.0.02026-12-01
First version: a first message to a Marketplace listing's seller, or a reply in one of the account's conversations, sent once as Facebook's own page sends it and answered as the message Facebook keeps. 5 messages a day an account, 20 to 40 seconds apart.