POSTapi.synup.com/api/v4/automations/temporary-close-location-with-reopening-date
Temporary Close Location with a reopening date
Temporary close a location with a reopening date. Note : Ensure your account has automation part of your subscriptions. This functionality is supported only for Google and Facebook Listings.
Requires an API key. Send it as
Authorization: API <your-key> — see Getting started.Parameters
Body
| Name | Type | Required | Description |
|---|---|---|---|
input | object | required | |
input.name | string | required | |
input.startDate | string | required | |
input.startTime | string | required | |
input.endDate | string | required | |
input.locationId | string | required |
Request
Request
curl -X POST 'https://api.synup.com/api/v4/automations/temporary-close-location-with-reopening-date' \
-H 'Authorization: API YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"input": {
"name": "Automation to temporary close a Location",
"startDate": "2025-02-25",
"startTime": "10:59:51",
"endDate": "2025-02-28",
"locationId": "85006"
}
}'const res = await fetch('https://api.synup.com/api/v4/automations/temporary-close-location-with-reopening-date', {
method: 'POST',
headers: {
Authorization: 'API YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"input": {
"name": "Automation to temporary close a Location",
"startDate": "2025-02-25",
"startTime": "10:59:51",
"endDate": "2025-02-28",
"locationId": "85006"
}
}),
});
const data = await res.json();import requests
res = requests.post(
"https://api.synup.com/api/v4/automations/temporary-close-location-with-reopening-date",
headers={
"Authorization": "API YOUR_API_KEY",
"Content-Type": "application/json",
},
json={
"input": {
"name": "Automation to temporary close a Location",
"startDate": "2025-02-25",
"startTime": "10:59:51",
"endDate": "2025-02-28",
"locationId": "85006"
}
},
)
data = res.json()req, _ := http.NewRequest("POST", "https://api.synup.com/api/v4/automations/temporary-close-location-with-reopening-date", bytes.NewBufferString(payload))
req.Header.Set("Authorization", "API YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)Responses
| Status | Description |
|---|---|
200 |
Example response
{
"data": {
"createFlowFromRecipe": {
"success": true,
"flow": {
"id": "52d903f2-6736-4012-930d-ec5872a690b3"
}
}
}
}Response body
| Name | Type | Required | Description |
|---|---|---|---|
data | object | required | |
data.createFlowFromRecipe | object | required | |
data.createFlowFromRecipe.success | boolean | required | |
data.createFlowFromRecipe.flow | object | required | |
data.createFlowFromRecipe.flow.id | string | required |