Editorials Last updated: 2020-09-16

The Editorial resource stores long text information used for various informational purposes throughout the site. Typical editorials include privacy policies, faq's, and size charts.

What you can do with editorials:
Editorial Properties
Property Description
OID "OID":  12321
The marketAgility ID for the editorial
SiteID "SiteID":  1
The marketAgility Site Id for the editorial
Name "Name":  "Privacy Policay"
The name of the editorial
Created "Created":  "2019-04-21T12:43:12"
The date the editorial was created
Modified "Modified":  "2020-05-12T08:03:00"
The date the editorial was last modified
Status "Status":  "Active"
Defines whether a editorial is active or inactive
OnlineStatus "OnlineStatus":  "Migrating"
The live status of a editorial (Staging, Migrating, Production)
OnlineDate "OnlineDate":  "2020-05-05T18:03:00"
The date and time this editorial was last updated in the production environment
ShortDescription "ShortDescription":  "Click here to read our privacy policy"
Limited text description of the editorial (255 characters)
LongDescription "LongDescription":  "This is a lot of text decribing our privacy policy"
A longer text description of the editorial (2000 characters)
Content "Content":  "This is the Privacy policay"
The actual content of the editorial (up to 1GB)
Keywords "Keywords":  "Keyword1, Keyword 2"
Keywords for searching and meta tags
URL "URL":  "https://www.virid.com"
External link to more information
Source "Source":  "Mary Jones"
Where did this content come from? (author, system, etc)
PublicationName "PublicationName":  "Wired Magazine"
Name of the Publication
PublicationDate "PublicationDate":  "Fall, 2020"
Text representation of the date of the publication
FullImage "FullImage":  "https://mabaseline.blob.core.windows.net/images/editorials/1_2649.jpg""
The Url of the full sized default image for the editorial
PreviewImage "PreviewImage":  "https://mabaseline.blob.core.windows.net/images/editorials/1_2649_m.jpg"
The Url of the mobile/preview sized default image for the editoriale

Get Editorial

Gets a single editorial by Id

GET /api/v3/editorials/2649

HTTP/1.1 200 OK
{
            "OID": 2649,
            "SiteID": 1,
            "Created": "2018-02-07T16:40:03.43Z",
            "Modified": "2018-02-07T16:40:03.43Z",
            "Status": "Active",
            "OnlineStatus": "Migrating",
            "OnlineDate": "2018-02-07T16:40:03.43Z",
            "Name": "Privacy Policy",
            "ShortDescription": "Short Description",
            "LongDescription": "Long Description",
            "Content": "The Content",
            "Keywords": "Key, Words",
            "URL": "https://www.virid.com",
            "Source": "Mary Jones",
            "PublicationName": "Wired Magazine",
            "PublicationDate": "Fall, 2020",
            "FullImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649.jpg",
            "PreviewImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649_m.jpg",
}

List Editorials

Retrieves a list of editorials for a marketAgility site.

GET /api/v3/editorials/

HTTP/1.1 200 OK
[
     {
            "OID": 2649,
            "SiteID": 1,
            "Created": "2018-02-07T16:40:03.43Z",
            "Modified": "2018-02-07T16:40:03.43Z",
            "Status": "Active",
            "OnlineStatus": "Migrating",
            "OnlineDate": "2018-02-07T16:40:03.43Z",
            "Name": "Privacy Policy",
            "ShortDescription": "Short Description",
            "LongDescription": "Long Description",
            "Content": "The Content",
            "Keywords": "Key, Words",
            "URL": "https://www.virid.com",
            "Source": "Mary Jones",
            "PublicationName": "Wired Magazine",
            "PublicationDate": "Fall, 2020",
            "FullImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649.jpg",
            "PreviewImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649_m.jpg",
    }
]

Create a new editorial

Create a editorial.

POST /api/v3/editorials/
{
    "Name": "Privacy Policy",
    "Content": "This is the Privacy Policay",
    "Source": "Mary Jones",
    "PublicationDate": "9-15-2020",
}
                                

HTTP/1.1 201 Created
{
            "OID": 2649,
            "SiteID": 1,
            "Created": "2018-02-07T16:40:03.43Z",
            "Modified": "2018-02-07T16:40:03.43Z",
            "Status": "Active",
            "OnlineStatus": "Migrating",
            "OnlineDate": "2018-02-07T16:40:03.43Z",
            "Name": "Privacy Policy",
            "ShortDescription": "Short Description",
            "LongDescription": "Long Description",
            "Content": "The Content",
            "Keywords": "Key, Words",
            "URL": "https://www.virid.com",
            "Source": "Mary Jones",
            "PublicationName": "Wired Magazine",
            "PublicationDate": "Fall, 2020",
            "FullImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649.jpg",
            "PreviewImage": "https://mabaseline.blob.core.windows.net/images/editorials/1_2649_m.jpg",
}

Update Editorial

Update an existing editorial

PUT /api/v3/editorials/2649
{
    "PublicationDate": "9-22-2020",
    "Content": "This is the new privacy policy"
}
                                

HTTP/1.1 204 No Content

Assets

The different assets available for an editorial. These are most commonly images, but can be links to videos or other digital asset types

What you can do with an Asset:
Asset Properties
Property Description
OID "OID":  42608
The marketAgility ID for an asset
Name "Name":  "Back"
The name of the asset
RelationCode "RelationCode":  "Back View"
The alt tag of the view, or the link text if the asset is an external link
URL "URL":  "https://www.viridi.com"
Optional Link to external content
Image "ThumbImage":  "https://mabaseline.blob.core.windows.net/..../1_42668_Back.JPG"
The URL for the asset's image

Get Assets

Get an asset for an editorial.

GET api/v3/editorials/2649/assets/41317

HTTP/1.1 200 OK
{
            "OID": 41317,
            "Name": "Back View",
            "RelationCode": "Back",
            "URL": ,
            "Image": "https://mabaseline.blob.core.windows.net/images/editorials/1_42668_Back%20View.jpg",
    
}

List Assets

Get all assets for an editorial.

GET api/v3/editorials/42668/assets

HTTP/1.1 200 OK
[
    {
            "OID": 41317,
            "Name": "Back View",
            "RelationCode": "Back",
            "URL": ,
            "Image": "https://mabaseline.blob.core.windows.net/images/editorials/1_42668_Back%20View.jpg",
    
    }
]

Create Asset

Create an asset for an editorial.

POST /api/v3/editorials/2649/assets
{
    "Name": "Back View",
    "Image": "https://somesite.com/source_image.png",
}
                            

HTTP/1.1 201 Created
{
            "OID": 41317,
            "Name": "Back View",
            "RelationCode": "Back",
            "URL": ,
            "Image": "https://mabaseline.blob.core.windows.net/images/editorials/1_42668_Back%20View.jpg",
}

Update Asset

Update an existing editorial asset View

PUT /api/v3/editorials/2649/assets/41317
{
    "Name": "Back View",
    "Image": "https://somesite.com/new_source_view.png",
}

                                

HTTP/1.1 204 No Content