[SalesForce] 405 – HTTP verb used to access this page is not allowed

I am trying to configure my POSTMAN as per the below article
https://gortonington.com/introduction-to-making-api-calls-to-sfmc-from-postman/

But I am facing the Error – 405 – HTTP verb used to access this page is not allowed.

I verified the below,
1) A valid "accessToken" is set. [confirmed by making a REST API]
2) All Environment variables are set correctly.
3) Set header variable, SoapAction: Retrieve

Code below for reference,

<?xml version="1.0" encoding="UTF-8"?>
<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:u="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
   <s:Header>
      <a:Action s:mustUnderstand="1">Retrieve</a:Action>
      <a:MessageID>urn:uuid:7e0cca04-57bd-4481-864c-6ea8039d2ea0</a:MessageID>
      <a:ReplyTo>
         <a:Address>http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address>
      </a:ReplyTo>
      <a:To s:mustUnderstand="1">{{soapEndPoint}}</a:To>
      <fueloauth xmlns="http://exacttarget.com">{{accessToken}}</fueloauth>
   </s:Header>
   <s:Body xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      <RetrieveRequestMsg xmlns="http://exacttarget.com/wsdl/partnerAPI">
         <RetrieveRequest>
            <ObjectType>Subscriber</ObjectType>
            <Properties>SubscriberKey</Properties>
            <Properties>EmailAddress</Properties>
            <Properties>Status</Properties>
            <Filter xmlns:q1="http://exacttarget.com/wsdl/partnerAPI" xsi:type="q1:SimpleFilterPart">
               <q1:Property>SubscriberKey</q1:Property>
               <q1:SimpleOperator>equals</q1:SimpleOperator>
               <q1:Value>0032E00002QV2wMQAT</q1:Value>
            </Filter>
         </RetrieveRequest>
      </RetrieveRequestMsg>
   </s:Body>
</s:Envelope>

Best Answer

As the documentation you linked suggests, the action is a POST (check the upper left dropdown).

post configuration sample

When you see an "http verb" error, it is likely that you are using the wrong verb (such as using GET instead of POST).

You can read more about HTTP verbs on the Mozilla docs.

Related Topic