Legacy Dev Forum Posts

 View Only

Sign Up

Send an outbound agenteless email via API

  • 1.  Send an outbound agenteless email via API

    Posted 06-05-2025 18:23

    Ale | 2022-10-18 13:05:49 UTC | #1

    Hello everyone, i'm trying to use the following API --> /api/v2/conversations/emails/agentless to send an outbound email automatically from an InQueue IVR flow. Here the body for the API :

    { "senderType": "", "conversationId": "", "fromAddress": { "email": "", "name": "" }, "toAddresses": [ { "email": "", "name": "" } ], "replyToAddress": { "email": "", "name": "" }, "subject": "", "textBody": "", "htmlBody": "" }.

    I compile the body in the following way (consider that the only required field are senderType , fromAddress , toAddresses) :

    { "senderType": "Outbound", "fromAddress": { "email": "The Genesys email address set-up under the contact-center email section of Gcloud" }, "toAddresses": [ { "email": "My email address" } ] } .

    But i have the response below :

    "message": "This request requires a non-user context. User token cannot be used for requests to this resource."

    What is the reason and how i can fix it? Thanks in advance, Alessandro


    anon14299330 | 2022-10-24 11:12:10 UTC | #2

    Hi,

    What is your authorization method? According to the error message, the request requires an non-user context, which means using an authorization method that does not provide a user context such as Client Credentials Grant. Other authorization methods like Authorization Code Grant or Implicit Grant provide a user context for requests.

    Thanks,

    Mike


    system | 2022-11-24 11:12:30 UTC | #3

    This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 16759