httppost() with a body of Json

I have used the httppost() function with soap calls but for some reason im having difficultys with the one below im not sure what i am missing but i get a "No HTTP resource was found that matches the request URI". 

local!customer: {id: 3020, name: "John"}

httppost(
endpoint: URL,
paramNames: {"prelarId"},
paramValues: {3020},
headerNames: {},
headerValues: {},
body: a!toJson(value: local!customer),
user: "Username",
password: "Password",
domain: ""
)

  Discussion posts and replies are publicly visible

Parents
  • I have figured it out for some reason the parmaNames will not go up to the url. Example: URL/?prelarId=3020

    i had to remove the paramNames and paramValues and place them at the end of the endpoint URL.

    httppost(
    endpoint: "URL/?prelarId" & "3020",
    paramNames: {},
    paramValues: {},
    headerNames: {},
    headerValues: {},
    body: a!toJson(value: local!customer),
    user: "Username",
    password: "Password",
    domain: ""
    )
Reply
  • I have figured it out for some reason the parmaNames will not go up to the url. Example: URL/?prelarId=3020

    i had to remove the paramNames and paramValues and place them at the end of the endpoint URL.

    httppost(
    endpoint: "URL/?prelarId" & "3020",
    paramNames: {},
    paramValues: {},
    headerNames: {},
    headerValues: {},
    body: a!toJson(value: local!customer),
    user: "Username",
    password: "Password",
    domain: ""
    )
Children
No Data