I'm attempting to create a program using the Marketo REST API. I seem to get a 200 response without a response body. Can someone help me understand what the problem might be?
API Route: POST /rest/asset/v1/programs
Request Body:
{
"type": "Default",
"channel": "Nurture Email",
"name": "EmailProgramTest",
"folder":
{
"type": "Folder",
"id": 619900
},
"costs":
[
{
"startDate":"2022-01-01",
"cost":2000
}
]
}
Solved! Go to Solution.
create program endpoint takes form data not json. as per the example in api docs, your payload should be something like:
name=EmailProgramTest&folder={"id":619900,"type":"Folder"}&type=Default&channel=Nurture Email&costs=[{"startDate":"2022-01-01","cost":2000}]
p.s. that's a really big number for folder id...
create program endpoint takes form data not json. as per the example in api docs, your payload should be something like:
name=EmailProgramTest&folder={"id":619900,"type":"Folder"}&type=Default&channel=Nurture Email&costs=[{"startDate":"2022-01-01","cost":2000}]
p.s. that's a really big number for folder id...