MeiroDocs

Global Blocks in Emails

Required feature: **emails/view**

Section: Group Global Blocks in Emails. Base URL: https://instance_name.meiro.io/api/.

Global Blocks [/emails/global_blocks]

List Global Blocks [GET]

Required feature: emails/view

  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 200 (application/json)

[
    {
        "id": "71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c",
        "name": "My global block",
        "content_json": "JSON content",
        "content_html": "<body></body>",
        "thumbnail_url": "https://me.instance.io/path/to/image.jpg",
        "modified": "2024-04-07T22:49:29Z",
        "modified_by": 4,
        "usage_count": 1,
    }
]

Create Global Block [POST]

Required feature: email_blocks/edit

  • Attributes

    • id: 71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c (string)
    • name: My global block (string)
    • content_json: {} (string)
    • content_html: <body></body> (string)
    • thumbnail_url: https://me.instance.io/path/to/image.jpg (string)
  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 201 (application/json)

{
    "id": "71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c",
    "name": "My global block",
    "content_json": "{}",
    "content_html": "<body></body>",
    "thumbnail_url": "https://me.instance.io/path/to/image.jpg",
    "modified": "2024-04-07T22:49:29Z",
    "modified_by": 4,
}

Global Block [/emails/global_blocks/{global_block_id}]

Get Global Block [GET]

Required feature: emails/view

  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 200 (application/json)

{
    "id": "71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c",
    "name": "My global block",
    "content_json": "{}",
    "content_html": "<body></body>",
    "thumbnail_url": "https://me.instance.io/path/to/image.jpg",
    "modified": "2024-04-07T22:49:29Z",
    "modified_by": 4,
}
  • Response 404 (application/json)

Modify a Global Block [PATCH]

Required feature: email_blocks/edit

  • Attributes

    • name: My renamed global block (string)
    • content_json: {} (string)
    • content_html: <body></body> (string)
    • thumbnail_url: https://me.instance.io/path/to/another/image.jpg (string)
  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 200 (application/json)

{
    "id": "71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c",
    "name": "My renamed global block",
    "content_json": "{}",
    "content_html": "<body></body>",
    "thumbnail_url": "https://me.instance.io/path/to/another/image.jpg",
    "modified": "2024-04-07T22:49:29Z",
    "modified_by": 4,
}

Delete a Global Block [DELETE]

Required feature: email_blocks/edit

  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 200 (application/json)

Global Block Usage [/emails/global_block_usage/{global_block_id}]

Global Blocks Email Usage [GET]

Required feature: emails/view

  • Request (application/json)

    • Headers

      X-Access-Token: 1234567890abcdef

  • Response 200 (application/json)

[
    {
        "email_id": "71e07c4e-caa0-4a0b-beb4-ab18f01ffb3c",
        "name": "Email campaign name",
    }
]

On this page