Landings
Landing API: /api/bw/v2/landing
API BW version 2 (Beta)
Allows you to add, update or delete Landings in a Boldest platform account. Among many other things, it can also be used to categorize Landings.
Methods
POST: Create/Update Landing
POST
jsonData to import in JSON format according to Schema /api/bw/v2/landing/schema.json
Consult the Schema documentation for the structure of the JSON data.
RESULT:
HTTP 200 Skipped. The Landing exists and does not need to be updated
{
"done": "Skip Landing TEST111",
"id": "TEST111",
"new": false,
"update": false
}
HTTP 201 Created. The Landing did not exist, so it was created
{
"done": "Create Landing TEST111",
"id": "TEST111",
"new": true,
"update": true
}
HTTP 202 Accepted. The Landing existed, so it was updated
{
"done": "Update Landing TEST111",
"id": "TEST111",
"new": false,
"update": true
}
HTTP 400 Wrong request
{
"fail": "Wrong request"
}
HTTP 401 Unauthorized
{
"fail": "Unauthorized"
}
HTTP 409 Conflict. The submitted contents are not valid
{
"fail": "Explanation of the problems encountered"
}
GET: Get Landing/s
/{ids}Id or Ids CSV format (Optional)/published/{1|0|*}Published (Optional) (Default:1)/fields/{fields}Only these fields (Optional) (Default:All)/ignoreFields/{fields}Ignore these fields (Optional) (Default:None)/excludeFilesIgnore file fields (Optional) (Default:No)RESULT:
HTTP 200SuccessLanding data in JSON format according to Schema (schema.json or schema.multiple.json)
HTTP 400Wrong request{ "fail": "Wrong request" }
HTTP 401Unauthorized{ "fail": "Unauthorized" }
HTTP 404Not found{ "fail": "ERROR: Export fail" }
DELETE: Delete Landing/s
/{ids}Id or Ids CSV formatRESULT:
HTTP 202Deleted{ "done": "Deletion of 5 Landings done", "count": 5 // Number of Landings deleted }
Partial deletion
{ "done": "Deletion of 3 Landings done", "count": 3, // Number of Landings deleted "fail": "Deletion of 2 Landings not done", "failed": ["TEST114", "TEST115"] }
HTTP 400Wrong request{ "fail": "Wrong request" }
HTTP 401Unauthorized{ "fail": "Unauthorized" }
HTTP 404Not found{ "fail": "No Landings to delete" }
HTTP 409Conflict. The submitted contents are not valid{ "fail": "Deletion of 5 Landings not done" }
POST/GET: Clone a Landing. Optionally can be added to a Map
/cloneCommand/{id}Id (Optional) (Default: Landing “Base” is cloned)RESULT:
HTTP 201Cloned{ "done": "Cloned Landing TEST111 to Landing TEST111_8PtTXiU6mcw", "id": "TEST111_8PtTXiU6mcw" }
HTTP 400Wrong request{ "fail": "Wrong request" }
HTTP 401Unauthorized{ "fail": "Unauthorized" }
HTTP 404Error{ "fail": "There is no Landing TEST111 to clone" }
HTTP 409Fail{ "fail": "Not cloned Landing TEST111" }
GET: Get Schema JSON from the data structure of a Landing
/fullSchema and data (Optinal)/schema.jsonJSON schema for importRESULT:
HTTP 200SuccessJSON schema document
GET: Get Schema JSON schema of a group of Landings in a batch process
/fullSchema and data (Optinal)/schema.multiple.jsonSchema for batch import JSONRESULT:
HTTP 200SuccessJSON schema document
Landing schema documentation
Properties:
These are the fields used in the JSON for the map creation and update API.
id (required) Type: string. Size: (3, 80)
Unique key that identifies the Landing
published Type: boolean
Visibility of the Landing
timeLastUpdate Type: string. Size: 19
Last update date and time (YYYY-MM-DD HH:MM:SS)
title Type: string. Size: (0, 100)
Title of the Landing
shortDescription Type: string (nullable). Size: (0, 160)
Snippet describing the Landing in brief
htmlDescription Type: string (nullable). Size: (0, 1000)
Summary paragraph describing the Landing executively (supports HTML)
htmlContent Type: string (nullable). Size: (0, 32000)
Full content describing the Landing (supports HTML)
image Type: uri (nullable)
Featured image representing the Landing (URL to jpg, png or webp)
urlAlias Type: string. Size: (2, 500)
URL of the Landing (not full URL. Without protocol and domain. Starts with /)
canonicalUrl Type: uri (nullable). Size: (0, 500)
URL of equivalent external Landing
alternativeView Type: string (nullable)
Alternative view of the Landing (default: null)
proposal Type: boolean
Proposal (Bool)
proposalSummary Type: string (nullable). Size: (0, 2000)
Proposal summary (HTML)
proposalCalendar Type: string (nullable). Size: (0, 2000)
Proposal calendar (HTML)
proposalDescription Type: string (nullable). Size: (0, 2000)
Proposal description (HTML)
landingBlocks Type: array(Type: object)
See below schema of properties of landingBlocks items
Content blocks for the Landing
landingHotels Type: array(Type: object)
See below schema of properties of landingHotels items
Hotels section in the Landing
mapIntro Type: string (nullable). Size: (0, 250)
Intro text for the map
mapId Type: string
Map displayed in the landing
ctaOnMap Type: boolean (nullable)
Activate the floating CTA button on the map.
ctaUrl Type: uri (nullable). Size: (0, 2000)
URL pointed to by the Landing CTA button
ctaLabel Type: string (nullable). Size: (0, 20)
CTA button: text label
ctaValuePrefix Type: string (nullable). Size: (0, 20)
CTA introduction text or pricing: Prefix
ctaValue Type: string (nullable). Size: (0, 20)
CTA introduction text or pricing: label
ctaValueSufix Type: string (nullable). Size: (0, 20)
CTA introduction text or pricing: Sufix
Schema landingBlocks item
title Type: string. Size: (0, 200)
Title of the block
shortDescription Type: string (nullable). Size: (0, 200)
Description of the block in brief (Plain text)
htmlContent Type: string (nullable). Size: (0, 32000)
Description of the block (HTML)
resourceIds Type: array(Type: string) (nullable)
Sorted array with the ‘id’ of the Maps or Landings to be displayed in the block
Schema landingHotels item
title Type: string. Size: (0, 200)
Title of the hotels block
shortDescription Type: string (nullable). Size: (0, 200)
Description of the hotels block in brief (Plain text)
htmlContent Type: string (nullable). Size: (0, 32000)
Description of the hotels block (HTML)
resourceIds Type: array(Type: string) (nullable)
Sorted array with the ‘id’ of the Resources (hotels) to be displayed in the block
Language information
This schema includes certain fields which have multiple languages support.
The following fields have multiple languages support:
title
shortDescription
htmlDescription
htmlContent
urlAlias
canonicalUrl
landingBlocks.title
landingBlocks.shortDescription
landingBlocks.htmlContent
landingHotels.title
landingHotels.shortDescription
landingHotels.htmlContent
proposalSummary
proposalCalendar
proposalDescription
buttonViewMapLabel
mapIntro
ctaValuePrefix
ctaValue
ctaValueSufix
ctaLabel
When you use the name of this fields without the suffix with language you are referring to the field in the default language.
If you want to use a field in a different language, you must add to the field name the language code separated by an underscore (_).
For example, if the proyect have English language and
you want to use the field title in English language,
you must add the language code en to the field name as title_en.