Marketo · Capability

Marketo Engage Rest API — Emails

Marketo Engage Rest API — Emails. 26 operations. Lead operation: Marketo Get Email by Name. Self-contained Naftiko capability covering one Marketo business surface.

Run with Naftiko MarketoEmails

What You Can Do

GET
Getemailbynameusingget — Marketo Get Email by Name
/v1/asset/v1/email/byname-json
GET
Getemailccfieldsusingget — Marketo Get Email CC Fields
/v1/asset/v1/email/ccfields-json
GET
Getemailbyidusingget — Marketo Get Email By Id
/v1/asset/v1/email/id-json
POST
Updateemailusingpost — Marketo Update Email Metadata
/v1/asset/v1/email/id-json
POST
Approvedraftusingpost — Marketo Approve Email Draft
/v1/asset/v1/email/{id}/approvedraft-json
POST
Cloneemailusingpost — Marketo Clone Email
/v1/asset/v1/email/{id}/clone-json
GET
Getemailcontentbyidusingget — Marketo Get Email Content
/v1/asset/v1/email/{id}/content-json
POST
Updateemailcontentusingpost — Marketo Update Email Content
/v1/asset/v1/email/{id}/content-json
POST
Rearrangemodulesusingpost — Marketo Rearrange Email Modules
/v1/asset/v1/email/{id}/content/rearrange-json
POST
Updateemailcomponentcontentusingpost — Marketo Update Email Content Section
/v1/asset/v1/email/{id}/content/htmlid-json
POST
Addmoduleusingpost — Marketo Add Email Module
/v1/asset/v1/email/{id}/content/{moduleid}/add-json
POST
Deletemoduleusingpost — Marketo Delete Module
/v1/asset/v1/email/{id}/content/{moduleid}/delete-json
POST
Duplicatemoduleusingpost — Marketo Duplicate Email Module
/v1/asset/v1/email/{id}/content/{moduleid}/duplicate-json
POST
Renameusingpost — Marketo Rename Email Module
/v1/asset/v1/email/{id}/content/{moduleid}/rename-json
POST
Deleteemailusingpost — Marketo Delete Email
/v1/asset/v1/email/{id}/delete-json
POST
Discarddraftusingpost — Marketo Discard Email Draft
/v1/asset/v1/email/{id}/discarddraft-json
GET
Getemaildynamiccontentusingget — Marketo Get Email Dynamic Content
/v1/asset/v1/email/{id}/dynamiccontent/contentid-json
POST
Updateemaildynamiccontentusingpost — Marketo Update Email Dynamic Content Section
/v1/asset/v1/email/{id}/dynamiccontent/contentid-json
GET
Getemailfullcontentusingget — Marketo Get Email Full Content
/v1/asset/v1/email/{id}/fullcontent-json
POST
Createemailfullcontentusingpost — Marketo Update Email Full Content
/v1/asset/v1/email/{id}/fullcontent-json
POST
Sendsampleemailusingpost — Marketo Send Sample Email
/v1/asset/v1/email/{id}/sendsample-json
POST
Unapprovedraftusingpost — Marketo Unapprove Email
/v1/asset/v1/email/{id}/unapprove-json
POST
Updatevariableusingpost — Marketo Update Email Variable
/v1/asset/v1/email/{id}/variable/name-json
GET
Getemailvariablesusingget — Marketo Get Email Variables
/v1/asset/v1/email/{id}/variables-json
GET
Getemailusingget — Marketo Get Emails
/v1/asset/v1/emails-json
POST
Createemailusingpost — Marketo Create Email
/v1/asset/v1/emails-json

MCP Tools

marketo-get-email-name

Marketo Get Email by Name

read-only idempotent
marketo-get-email-cc-fields

Marketo Get Email CC Fields

read-only idempotent
marketo-get-email-id

Marketo Get Email By Id

read-only idempotent
marketo-update-email-metadata

Marketo Update Email Metadata

marketo-approve-email-draft

Marketo Approve Email Draft

marketo-clone-email

Marketo Clone Email

marketo-get-email-content

Marketo Get Email Content

read-only idempotent
marketo-update-email-content

Marketo Update Email Content

marketo-rearrange-email-modules

Marketo Rearrange Email Modules

marketo-update-email-content-section

Marketo Update Email Content Section

marketo-add-email-module

Marketo Add Email Module

marketo-delete-module

Marketo Delete Module

marketo-duplicate-email-module

Marketo Duplicate Email Module

marketo-rename-email-module

Marketo Rename Email Module

marketo-delete-email

Marketo Delete Email

marketo-discard-email-draft

Marketo Discard Email Draft

marketo-get-email-dynamic-content

Marketo Get Email Dynamic Content

read-only idempotent
marketo-update-email-dynamic-content

Marketo Update Email Dynamic Content Section

marketo-get-email-full-content

Marketo Get Email Full Content

read-only idempotent
marketo-update-email-full-content

Marketo Update Email Full Content

marketo-send-sample-email

Marketo Send Sample Email

marketo-unapprove-email

Marketo Unapprove Email

marketo-update-email-variable

Marketo Update Email Variable

marketo-get-email-variables

Marketo Get Email Variables

read-only idempotent
marketo-get-emails

Marketo Get Emails

read-only idempotent
marketo-create-email

Marketo Create Email

Capability Spec

engage-rest-emails.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Marketo Engage Rest API — Emails
  description: 'Marketo Engage Rest API — Emails. 26 operations. Lead operation: Marketo Get Email by Name. Self-contained
    Naftiko capability covering one Marketo business surface.'
  tags:
  - Marketo
  - Emails
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    MARKETO_API_KEY: MARKETO_API_KEY
capability:
  consumes:
  - type: http
    namespace: engage-rest-emails
    baseUri: https://localhost:8080
    description: Marketo Engage Rest API — Emails business capability. Self-contained, no shared references.
    resources:
    - name: rest-asset-v1-email-byName.json
      path: /rest/asset/v1/email/byName.json
      operations:
      - name: getemailbynameusingget
        method: GET
        description: Marketo Get Email by Name
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: name
          in: query
          type: string
          description: Name of the email
          required: true
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions
        - name: folder
          in: query
          type: string
          description: JSON representation of parent folder, with members 'id', and 'type' which may be 'Folder' or 'Program'
    - name: rest-asset-v1-email-ccFields.json
      path: /rest/asset/v1/email/ccFields.json
      operations:
      - name: getemailccfieldsusingget
        method: GET
        description: Marketo Get Email CC Fields
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: rest-asset-v1-email-id}.json
      path: /rest/asset/v1/email/{id}.json
      operations:
      - name: getemailbyidusingget
        method: GET
        description: Marketo Get Email By Id
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions
      - name: updateemailusingpost
        method: POST
        description: Marketo Update Email Metadata
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-approveDraft.json
      path: /rest/asset/v1/email/{id}/approveDraft.json
      operations:
      - name: approvedraftusingpost
        method: POST
        description: Marketo Approve Email Draft
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
    - name: rest-asset-v1-email-id-clone.json
      path: /rest/asset/v1/email/{id}/clone.json
      operations:
      - name: cloneemailusingpost
        method: POST
        description: Marketo Clone Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-content.json
      path: /rest/asset/v1/email/{id}/content.json
      operations:
      - name: getemailcontentbyidusingget
        method: GET
        description: Marketo Get Email Content
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions
      - name: updateemailcontentusingpost
        method: POST
        description: Marketo Update Email Content
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-content-rearrange.json
      path: /rest/asset/v1/email/{id}/content/rearrange.json
      operations:
      - name: rearrangemodulesusingpost
        method: POST
        description: Marketo Rearrange Email Modules
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: rest-asset-v1-email-id-content-htmlId}.json
      path: /rest/asset/v1/email/{id}/content/{htmlId}.json
      operations:
      - name: updateemailcomponentcontentusingpost
        method: POST
        description: Marketo Update Email Content Section
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: htmlId
          in: path
          type: string
          description: htmlId
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-content-moduleId-add.json
      path: /rest/asset/v1/email/{id}/content/{moduleId}/add.json
      operations:
      - name: addmoduleusingpost
        method: POST
        description: Marketo Add Email Module
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: moduleId
          in: path
          type: string
          description: moduleId
          required: true
        - name: name
          in: query
          type: string
          description: Name of the module
          required: true
        - name: index
          in: query
          type: integer
          description: Index of the module. Determines the order of the module in the email.
          required: true
    - name: rest-asset-v1-email-id-content-moduleId-delete.json
      path: /rest/asset/v1/email/{id}/content/{moduleId}/delete.json
      operations:
      - name: deletemoduleusingpost
        method: POST
        description: Marketo Delete Module
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: moduleId
          in: path
          type: string
          description: moduleId
          required: true
    - name: rest-asset-v1-email-id-content-moduleId-duplicate.json
      path: /rest/asset/v1/email/{id}/content/{moduleId}/duplicate.json
      operations:
      - name: duplicatemoduleusingpost
        method: POST
        description: Marketo Duplicate Email Module
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: moduleId
          in: path
          type: string
          description: moduleId
          required: true
        - name: name
          in: query
          type: string
          description: Name of the new module
          required: true
    - name: rest-asset-v1-email-id-content-moduleId-rename.json
      path: /rest/asset/v1/email/{id}/content/{moduleId}/rename.json
      operations:
      - name: renameusingpost
        method: POST
        description: Marketo Rename Email Module
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: moduleId
          in: path
          type: string
          description: moduleId
          required: true
        - name: name
          in: query
          type: string
          description: New module name
          required: true
    - name: rest-asset-v1-email-id-delete.json
      path: /rest/asset/v1/email/{id}/delete.json
      operations:
      - name: deleteemailusingpost
        method: POST
        description: Marketo Delete Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
    - name: rest-asset-v1-email-id-discardDraft.json
      path: /rest/asset/v1/email/{id}/discardDraft.json
      operations:
      - name: discarddraftusingpost
        method: POST
        description: Marketo Discard Email Draft
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
    - name: rest-asset-v1-email-id-dynamicContent-contentId}.json
      path: /rest/asset/v1/email/{id}/dynamicContent/{contentId}.json
      operations:
      - name: getemaildynamiccontentusingget
        method: GET
        description: Marketo Get Email Dynamic Content
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: Id of email
          required: true
        - name: contentId
          in: path
          type: string
          description: Id of email dynamic content section
          required: true
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions
      - name: updateemaildynamiccontentusingpost
        method: POST
        description: Marketo Update Email Dynamic Content Section
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: Id of email
          required: true
        - name: contentId
          in: path
          type: string
          description: Id of email dynamic content section
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-fullContent.json
      path: /rest/asset/v1/email/{id}/fullContent.json
      operations:
      - name: getemailfullcontentusingget
        method: GET
        description: Marketo Get Email Full Content
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: Id of the email
          required: true
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions. Defaults to approved if asset is approved, draft if not.
        - name: leadId
          in: query
          type: integer
          description: The lead id to impersonate. Email is rendered as though it was received by this lead.
        - name: type
          in: query
          type: string
          description: Email content type to return. Default is HTML.
      - name: createemailfullcontentusingpost
        method: POST
        description: Marketo Update Email Full Content
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: Id of the email
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-sendSample.json
      path: /rest/asset/v1/email/{id}/sendSample.json
      operations:
      - name: sendsampleemailusingpost
        method: POST
        description: Marketo Send Sample Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: Id of the email
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: rest-asset-v1-email-id-unapprove.json
      path: /rest/asset/v1/email/{id}/unapprove.json
      operations:
      - name: unapprovedraftusingpost
        method: POST
        description: Marketo Unapprove Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
    - name: rest-asset-v1-email-id-variable-name}.json
      path: /rest/asset/v1/email/{id}/variable/{name}.json
      operations:
      - name: updatevariableusingpost
        method: POST
        description: Marketo Update Email Variable
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
        - name: name
          in: path
          type: string
          description: name
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: rest-asset-v1-email-id-variables.json
      path: /rest/asset/v1/email/{id}/variables.json
      operations:
      - name: getemailvariablesusingget
        method: GET
        description: Marketo Get Email Variables
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: id
          required: true
    - name: rest-asset-v1-emails.json
      path: /rest/asset/v1/emails.json
      operations:
      - name: getemailusingget
        method: GET
        description: Marketo Get Emails
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: status
          in: query
          type: string
          description: Status filter for draft or approved versions
        - name: folder
          in: query
          type: string
          description: JSON representation of parent folder, with members 'id', and 'type' which may be 'Folder' or 'Program'
        - name: offset
          in: query
          type: integer
          description: Integer offset for paging
        - name: maxReturn
          in: query
          type: integer
          description: Maximum number of emails to return. Max 200, default 20
        - name: earliestUpdatedAt
          in: query
          type: string
          description: Exclude emails prior to this date. Must be valid ISO-8601 string. See <a href="http://developers.marketo.com/rest-api/lead-database/fields/field-types/">Datetim
        - name: latestUpdatedAt
          in: query
          type: string
          description: Exclude emails after this date. Must be valid ISO-8601 string. See <a href="http://developers.marketo.com/rest-api/lead-database/fields/field-types/">Datetime</
      - name: createemailusingpost
        method: POST
        description: Marketo Create Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
  exposes:
  - type: rest
    namespace: engage-rest-emails-rest
    port: 8080
    description: REST adapter for Marketo Engage Rest API — Emails. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/asset/v1/email/byname-json
      name: rest-asset-v1-email-byname-json
      description: REST surface for rest-asset-v1-email-byName.json.
      operations:
      - method: GET
        name: getemailbynameusingget
        description: Marketo Get Email by Name
        call: engage-rest-emails.getemailbynameusingget
        with:
          name: rest.name
          status: rest.status
          folder: rest.folder
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/ccfields-json
      name: rest-asset-v1-email-ccfields-json
      description: REST surface for rest-asset-v1-email-ccFields.json.
      operations:
      - method: GET
        name: getemailccfieldsusingget
        description: Marketo Get Email CC Fields
        call: engage-rest-emails.getemailccfieldsusingget
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/id-json
      name: rest-asset-v1-email-id-json
      description: REST surface for rest-asset-v1-email-id}.json.
      operations:
      - method: GET
        name: getemailbyidusingget
        description: Marketo Get Email By Id
        call: engage-rest-emails.getemailbyidusingget
        with:
          id: rest.id
          status: rest.status
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: updateemailusingpost
        description: Marketo Update Email Metadata
        call: engage-rest-emails.updateemailusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/approvedraft-json
      name: rest-asset-v1-email-id-approvedraft-json
      description: REST surface for rest-asset-v1-email-id-approveDraft.json.
      operations:
      - method: POST
        name: approvedraftusingpost
        description: Marketo Approve Email Draft
        call: engage-rest-emails.approvedraftusingpost
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/clone-json
      name: rest-asset-v1-email-id-clone-json
      description: REST surface for rest-asset-v1-email-id-clone.json.
      operations:
      - method: POST
        name: cloneemailusingpost
        description: Marketo Clone Email
        call: engage-rest-emails.cloneemailusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content-json
      name: rest-asset-v1-email-id-content-json
      description: REST surface for rest-asset-v1-email-id-content.json.
      operations:
      - method: GET
        name: getemailcontentbyidusingget
        description: Marketo Get Email Content
        call: engage-rest-emails.getemailcontentbyidusingget
        with:
          id: rest.id
          status: rest.status
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: updateemailcontentusingpost
        description: Marketo Update Email Content
        call: engage-rest-emails.updateemailcontentusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/rearrange-json
      name: rest-asset-v1-email-id-content-rearrange-json
      description: REST surface for rest-asset-v1-email-id-content-rearrange.json.
      operations:
      - method: POST
        name: rearrangemodulesusingpost
        description: Marketo Rearrange Email Modules
        call: engage-rest-emails.rearrangemodulesusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/htmlid-json
      name: rest-asset-v1-email-id-content-htmlid-json
      description: REST surface for rest-asset-v1-email-id-content-htmlId}.json.
      operations:
      - method: POST
        name: updateemailcomponentcontentusingpost
        description: Marketo Update Email Content Section
        call: engage-rest-emails.updateemailcomponentcontentusingpost
        with:
          id: rest.id
          htmlId: rest.htmlId
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/{moduleid}/add-json
      name: rest-asset-v1-email-id-content-moduleid-add-json
      description: REST surface for rest-asset-v1-email-id-content-moduleId-add.json.
      operations:
      - method: POST
        name: addmoduleusingpost
        description: Marketo Add Email Module
        call: engage-rest-emails.addmoduleusingpost
        with:
          id: rest.id
          moduleId: rest.moduleId
          name: rest.name
          index: rest.index
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/{moduleid}/delete-json
      name: rest-asset-v1-email-id-content-moduleid-delete-json
      description: REST surface for rest-asset-v1-email-id-content-moduleId-delete.json.
      operations:
      - method: POST
        name: deletemoduleusingpost
        description: Marketo Delete Module
        call: engage-rest-emails.deletemoduleusingpost
        with:
          id: rest.id
          moduleId: rest.moduleId
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/{moduleid}/duplicate-json
      name: rest-asset-v1-email-id-content-moduleid-duplicate-json
      description: REST surface for rest-asset-v1-email-id-content-moduleId-duplicate.json.
      operations:
      - method: POST
        name: duplicatemoduleusingpost
        description: Marketo Duplicate Email Module
        call: engage-rest-emails.duplicatemoduleusingpost
        with:
          id: rest.id
          moduleId: rest.moduleId
          name: rest.name
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/content/{moduleid}/rename-json
      name: rest-asset-v1-email-id-content-moduleid-rename-json
      description: REST surface for rest-asset-v1-email-id-content-moduleId-rename.json.
      operations:
      - method: POST
        name: renameusingpost
        description: Marketo Rename Email Module
        call: engage-rest-emails.renameusingpost
        with:
          id: rest.id
          moduleId: rest.moduleId
          name: rest.name
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/delete-json
      name: rest-asset-v1-email-id-delete-json
      description: REST surface for rest-asset-v1-email-id-delete.json.
      operations:
      - method: POST
        name: deleteemailusingpost
        description: Marketo Delete Email
        call: engage-rest-emails.deleteemailusingpost
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/discarddraft-json
      name: rest-asset-v1-email-id-discarddraft-json
      description: REST surface for rest-asset-v1-email-id-discardDraft.json.
      operations:
      - method: POST
        name: discarddraftusingpost
        description: Marketo Discard Email Draft
        call: engage-rest-emails.discarddraftusingpost
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/dynamiccontent/contentid-json
      name: rest-asset-v1-email-id-dynamiccontent-contentid-json
      description: REST surface for rest-asset-v1-email-id-dynamicContent-contentId}.json.
      operations:
      - method: GET
        name: getemaildynamiccontentusingget
        description: Marketo Get Email Dynamic Content
        call: engage-rest-emails.getemaildynamiccontentusingget
        with:
          id: rest.id
          contentId: rest.contentId
          status: rest.status
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: updateemaildynamiccontentusingpost
        description: Marketo Update Email Dynamic Content Section
        call: engage-rest-emails.updateemaildynamiccontentusingpost
        with:
          id: rest.id
          contentId: rest.contentId
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/fullcontent-json
      name: rest-asset-v1-email-id-fullcontent-json
      description: REST surface for rest-asset-v1-email-id-fullContent.json.
      operations:
      - method: GET
        name: getemailfullcontentusingget
        description: Marketo Get Email Full Content
        call: engage-rest-emails.getemailfullcontentusingget
        with:
          id: rest.id
          status: rest.status
          leadId: rest.leadId
          type: rest.type
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createemailfullcontentusingpost
        description: Marketo Update Email Full Content
        call: engage-rest-emails.createemailfullcontentusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/sendsample-json
      name: rest-asset-v1-email-id-sendsample-json
      description: REST surface for rest-asset-v1-email-id-sendSample.json.
      operations:
      - method: POST
        name: sendsampleemailusingpost
        description: Marketo Send Sample Email
        call: engage-rest-emails.sendsampleemailusingpost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/unapprove-json
      name: rest-asset-v1-email-id-unapprove-json
      description: REST surface for rest-asset-v1-email-id-unapprove.json.
      operations:
      - method: POST
        name: unapprovedraftusingpost
        description: Marketo Unapprove Email
        call: engage-rest-emails.unapprovedraftusingpost
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/variable/name-json
      name: rest-asset-v1-email-id-variable-name-json
      description: REST surface for rest-asset-v1-email-id-variable-name}.json.
      operations:
      - method: POST
        name: updatevariableusingpost
        description: Marketo Update Email Variable
        call: engage-rest-emails.updatevariableusingpost
        with:
          id: rest.id
          name: rest.name
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/email/{id}/variables-json
      name: rest-asset-v1-email-id-variables-json
      description: REST surface for rest-asset-v1-email-id-variables.json.
      operations:
      - method: GET
        name: getemailvariablesusingget
        description: Marketo Get Email Variables
        call: engage-rest-emails.getemailvariablesusingget
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/asset/v1/emails-json
      name: rest-asset-v1-emails-json
      description: REST surface for rest-asset-v1-emails.json.
      operations:
      - method: GET
        name: getemailusingget
        description: Marketo Get Emails
        call: engage-rest-emails.getemailusingget
        with:
          status: rest.status
          folder: rest.folder
          offset: rest.offset
          maxReturn: rest.maxReturn
          earliestUpdatedAt: rest.earliestUpdatedAt
          latestUpdatedAt: rest.latestUpdatedAt
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createemailusingpost
        description: Marketo Create Email
        call: engage-rest-emails.createemailusingpost
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: engage-rest-emails-mcp
    port: 9090
    transport: http
    description: MCP adapter for Marketo Engage Rest API — Emails. One tool per consumed operation, routed inline through
      this capability's consumes block.
    tools:
    - name: marketo-get-email-name
      description: Marketo Get Email by Name
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: engage-rest-emails.getemailbynameusingget
      with:
        name: tools.name
        status: tools.status
        folder: tools.folder
      outputParameters:
      - type: object
        mapping: $.
    - name: marketo-get-email-cc-fields
      description: Marketo Get Email CC Fields
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: engage-rest-emails.getemailccfieldsusingget
      outputParameters:
      - type: object
        mapping: $.
    - name: marketo-get-email-id
      description: Marketo Get Email By Id
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: engage-rest-emails.getemailbyidusingget
      with:
        id: tools.id
        status: tools.status
      outputParameters:
      - type: object
        mapping: $.
    - name: marketo-update-email-metadata
      description: Marketo Update Email Metadata
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: engage-rest-emails.updateemailusingpost
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: marketo-approve-email-draft
      description: Marketo Approve Email Draft
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: engage-rest-emails.approvedraftusingpost
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: marketo-clone-email
      description: Marketo Clone Email
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: engage-rest-emails.cloneemailusingpost
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping

# --- truncated at 32 KB (39 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/marketo/refs/heads/main/capabilities/engage-rest-emails.yaml