Issues

API for managing issues

List Issues

GET https://www.magloft.com/api/portal/v1/issues/:app_id

This endpoint returns a list of all issues that belong to the magazine

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

Query Parameters

NameTypeDescription

screen_type

String

Screen Type

source

String

Source type of issue

url_scheme

String

generator

String

Generator

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Retrieve paginated list of issues

GET https://www.magloft.com/api/portal/v1/issues/:app_id/page/:page

This endpoint returns a page list of all issues that belong to the magazine

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

page

Integer

The page number to list

Query Parameters

NameTypeDescription

per_page

Integer

Number of items to show per page

order_by

Symbol

Field to sort results by

order_dir

Symbol

Direction (asc, desc) to sort results by

filter

String

Text filter to search results by

{
  "total": 1,
  "page": 1,
  "records": [
    {
      "id": 1234,
      "title": "Welcome to MagLoft",
      "info": null,
      "hpub": null,
      "source_file": null,
      "source": "typeloft",
      "unlock_type": "free",
      "hide_locked": false,
      "categories": [
        "Sports",
        "Business",
        "Politics"
      ],
      "category_ids": [
        1,
        2,
        3
      ],
      "classifications": [
        "Sports",
        "Business",
        "Politics"
      ],
      "classification_ids": [
        1,
        2,
        3
      ],
      "product_id": "purchase.issue_123456789",
      "product_id_apple": null,
      "product_id_google": null,
      "product_id_amazon": null,
      "screen_type": "issue",
      "publication_id": null,
      "coupon_code": null,
      "dirty": false,
      "user_id": null,
      "custom_stylesheet": null,
      "custom_data": null,
      "price_tier": null,
      "cover": null,
      "generator": "pdfix"
    }
  ]
}

Get Issue

GET https://www.magloft.com/api/portal/v1/issues/:app_id/:id

This endpoint returns a specific issue by id

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Download Issue

GET https://www.magloft.com/api/portal/v1/issues/:app_id/:id/download

This endpoint redirects to a specific issue HPUB url

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

null

Download a specific issue source

GET https://www.magloft.com/api/portal/v1/issues/:app_id/:id/source

This endpoint redirects to a specific issue source file url

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

null

Create an Issue

POST https://www.magloft.com/api/portal/v1/issues/:app_id

This endpoint creates a new issue and returns the saved issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

Request Body

NameTypeDescription

user_id

Integer

Issue User ID

title

String

Issue Title

info

String

Issue information

date

String

Issue publish date

product_id

String

Issue product id

product_id_apple

String

Issue product id (Apple)

product_id_google

String

Issue product id (Google)

product_id_amazon

String

Issue product id (Amazon)

unlock_type

String

Unlock Type

hide_locked

Virtus::Attribute::Boolean

Hide if Locked

price_tier

Integer

Issue price tier

design_id

Integer

Issue typeloft theme id

cover

String

Issue Cover

hpub

String

Issue HPUB Path

source_file

String

Issue Source File

source

String

Source type of issue

category_ids

Array

Issue category IDs

classification_ids

Array

Issue classification IDs

properties

Hash

Issue properties

status

Symbol

create_pages

Virtus::Attribute::Boolean

publish

Virtus::Attribute::Boolean

screen_type

String

file_size

Integer

generator

String

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Update an Issue

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id

This endpoint updates a specific issue by id and returns the updated issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

Request Body

NameTypeDescription

title

String

Issue Title

info

String

Issue information

date

String

Issue publish date

product_id

String

Issue product id

product_id_apple

String

Issue product id (Apple)

product_id_google

String

Issue product id (Google)

product_id_amazon

String

Issue product id (Amazon)

unlock_type

String

Unlock Type

hide_locked

Virtus::Attribute::Boolean

Hide if Locked

price_tier

Integer

Issue price tier

cover

String

Issue Cover

hpub

String

Issue HPUB Path

source_file

String

Issue Source File

source

String

Source type of issue

category_ids

Array

Issue category IDs

classification_ids

Array

Issue classification IDs

status

Symbol

jid_status

Symbol

custom_data

Hash

Custom Data Hash

custom_data[language]

String

custom_data[copy_of]

String

screenshots

[String]

properties

Hash

Issue properties

properties[page_turn_tap]

Virtus::Attribute::Boolean

properties[vertical_bounce]

Virtus::Attribute::Boolean

properties[max_zoom_level]

Float

properties[dual_spread]

Virtus::Attribute::Boolean

properties[dual_spread_cover]

Virtus::Attribute::Boolean

properties[default_orientation]

String

properties[orientation_phone]

String

properties[orientation_tablet]

String

properties[converted_to_typeloft]

Virtus::Attribute::Boolean

properties[reverse_page_order]

Virtus::Attribute::Boolean

properties[link_style]

String

properties[allowed_devices]

[String]

properties[allowed_platforms]

[String]

properties[navigator]

Virtus::Attribute::Boolean

properties[cover_colors]

[String]

properties[features]

[String]

properties[web_url]

String

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Clone an Issue

POST https://www.magloft.com/api/portal/v1/issues/:app_id/:id/clone/:magazine_id

This endpoint creates a new issue by cloning an existing issue and returns the saved issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

magazine_id

Integer

Cloned Issue target magazine ID

Request Body

NameTypeDescription

user_id

Integer

Issue User ID

cloneTitle

String

Cloned Issue title

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Sort Issue Articles

POST https://www.magloft.com/api/portal/v1/issues/:app_id/:id/sort

This endpoint sorts a set of articles of an issue by ids and returns an empty response with status 204

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

Request Body

NameTypeDescription

article_ids

Array

null

Convert Issue

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id/convert

This endpoint converts an issue from PDF, EPUB or Folio

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Pack an issue to HPUB

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id/pack

This endpoint pack an issue to HPUB and returns the issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Export issue to PDF

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id/export_pdf

This endpoint converts a TypeLoft 2 issue to PDF and returns the issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Generate Web URL

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id/generate_web_url

This endpoint generates a hosted version of an issue

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

{
  "id": 1234,
  "title": "Welcome to MagLoft",
  "info": null,
  "hpub": null,
  "source_file": null,
  "source": "typeloft",
  "unlock_type": "free",
  "hide_locked": false,
  "categories": [
    "Sports",
    "Business",
    "Politics"
  ],
  "category_ids": [
    1,
    2,
    3
  ],
  "classifications": [
    "Sports",
    "Business",
    "Politics"
  ],
  "classification_ids": [
    1,
    2,
    3
  ],
  "product_id": "purchase.issue_123456789",
  "product_id_apple": null,
  "product_id_google": null,
  "product_id_amazon": null,
  "screen_type": "issue",
  "publication_id": null,
  "coupon_code": null,
  "dirty": false,
  "user_id": null,
  "custom_stylesheet": null,
  "custom_data": null,
  "price_tier": null,
  "cover": null,
  "generator": "pdfix"
}

Process Filename

PUT https://www.magloft.com/api/portal/v1/issues/:app_id/:id/process_links

This endpoint process an issue filename links in TypeLoft Pages and returns an empty response with status 204

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

null

Delete Issue

DELETE https://www.magloft.com/api/portal/v1/issues/:app_id/:id

This endpoint deletes a specific issue by id and returns an empty response with status 204

Path Parameters

NameTypeDescription

app_id

String

App ID (Publication) to scope this request for.

id

Integer

Issue ID

null

Last updated