{
  "service": "retently",
  "displayName": "Retently",
  "categories": [
    "Marketing",
    "Data"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "API Key",
      "placeholder": "RETENTLY_API_KEY",
      "description": "Retently API key sent in the X-Api-Key header. Create and manage API keys in Retently account settings, and see the official authentication docs: https://help.retently.com/en/articles/13106739-api-authentication-options."
    }
  ],
  "homepageUrl": "https://www.retently.com/",
  "actions": [
    {
      "id": "retently.get_account_status",
      "service": "retently",
      "name": "get_account_status",
      "description": "Get Retently account identity, plan, survey credit, and usage counters for the authenticated API key.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "The input payload for getting Retently account status."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "account": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "plan": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "usage": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "cache": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "account",
          "plan",
          "usage",
          "cache",
          "raw"
        ],
        "description": "The response returned when getting Retently account status."
      }
    },
    {
      "id": "retently.get_customer",
      "service": "retently",
      "name": "get_customer",
      "description": "Get a Retently customer by customer ID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "customerId": {
            "type": "string",
            "minLength": 1,
            "description": "The Retently customer ID."
          }
        },
        "additionalProperties": false,
        "required": [
          "customerId"
        ],
        "description": "The input payload for getting a Retently customer."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "customer": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "customer",
          "raw"
        ],
        "description": "The response returned when getting a Retently customer."
      }
    },
    {
      "id": "retently.get_feedback",
      "service": "retently",
      "name": "get_feedback",
      "description": "Get a Retently feedback response by feedback ID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "feedbackId": {
            "type": "string",
            "minLength": 1,
            "description": "The Retently feedback ID."
          }
        },
        "additionalProperties": false,
        "required": [
          "feedbackId"
        ],
        "description": "The input payload for getting Retently feedback."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "feedback": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "feedback",
          "raw"
        ],
        "description": "The response returned when getting Retently feedback."
      }
    },
    {
      "id": "retently.get_template",
      "service": "retently",
      "name": "get_template",
      "description": "Get a Retently survey template by template ID, including survey questions when Retently returns them.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "templateId": {
            "type": "string",
            "minLength": 1,
            "description": "The Retently template ID."
          }
        },
        "additionalProperties": false,
        "required": [
          "templateId"
        ],
        "description": "The input payload for getting a Retently template."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "template": {
            "anyOf": [
              {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw object returned by Retently."
              },
              {
                "type": "null"
              }
            ]
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "template",
          "raw"
        ],
        "description": "The response returned when getting a Retently template."
      }
    },
    {
      "id": "retently.list_campaigns",
      "service": "retently",
      "name": "list_campaigns",
      "description": "List Retently survey campaigns.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "The input payload for listing Retently campaigns."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "campaigns": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "The raw object returned by Retently."
            },
            "description": "The campaigns returned by Retently."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "campaigns",
          "raw"
        ],
        "description": "The response returned when listing Retently campaigns."
      }
    },
    {
      "id": "retently.list_customers",
      "service": "retently",
      "name": "list_customers",
      "description": "List Retently customers with optional email, pagination, sorting, date range, and attribute filters.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "description": "Find a customer by email address.",
            "format": "email"
          },
          "page": {
            "type": "integer",
            "minimum": 1,
            "description": "The current page number. Retently defaults to page 1."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1000,
            "description": "The maximum number of items to return. Retently allows up to 1,000."
          },
          "sort": {
            "type": "string",
            "minLength": 1,
            "description": "The Retently sort option. Prefix the field with '-' for descending order."
          },
          "startDate": {
            "type": "string",
            "minLength": 1,
            "description": "The date boundary as an ISO timestamp or UNIX timestamp accepted by Retently."
          },
          "endDate": {
            "type": "string",
            "minLength": 1,
            "description": "The date boundary as an ISO timestamp or UNIX timestamp accepted by Retently."
          },
          "attributes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently customer property name to filter by."
                },
                "op": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently filter operator, such as equal or not_equal."
                },
                "value": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently customer property value to compare."
                }
              },
              "additionalProperties": false,
              "required": [
                "name",
                "op",
                "value"
              ],
              "description": "A Retently customer attribute filter."
            },
            "description": "Retently customer property filters.",
            "minItems": 1
          },
          "match": {
            "type": "string",
            "enum": [
              "all",
              "any"
            ],
            "description": "How Retently should combine multiple attribute filters."
          }
        },
        "additionalProperties": false,
        "description": "The input payload for listing Retently customers."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "customers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "The raw object returned by Retently."
            },
            "description": "The customers returned by Retently."
          },
          "pagination": {
            "type": "object",
            "properties": {
              "page": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The current page number returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pages": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of pages returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "limit": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The page size returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sort": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Retently sort value returned in the response."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "total": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of matching records returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "required": [
              "page",
              "pages",
              "limit",
              "sort",
              "total"
            ],
            "description": "Pagination metadata returned by Retently when present."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "customers",
          "pagination",
          "raw"
        ],
        "description": "The response returned when listing Retently customers."
      }
    },
    {
      "id": "retently.list_feedback",
      "service": "retently",
      "name": "list_feedback",
      "description": "List Retently survey feedback responses with optional customer, campaign, pagination, date, and attribute filters.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "description": "Search feedback responses by customer email address.",
            "format": "email"
          },
          "customerId": {
            "type": "string",
            "minLength": 1,
            "description": "Search feedback responses by Retently customer ID."
          },
          "campaignId": {
            "type": "string",
            "minLength": 1,
            "description": "Filter feedback responses by Retently campaign ID."
          },
          "page": {
            "type": "integer",
            "minimum": 1,
            "description": "The current page number. Retently defaults to page 1."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1000,
            "description": "The maximum number of items to return. Retently allows up to 1,000."
          },
          "sort": {
            "type": "string",
            "minLength": 1,
            "description": "The Retently sort option. Prefix the field with '-' for descending order."
          },
          "startDate": {
            "type": "string",
            "minLength": 1,
            "description": "The date boundary as an ISO timestamp or UNIX timestamp accepted by Retently."
          },
          "endDate": {
            "type": "string",
            "minLength": 1,
            "description": "The date boundary as an ISO timestamp or UNIX timestamp accepted by Retently."
          },
          "attributes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently customer property name to filter by."
                },
                "op": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently filter operator, such as equal or not_equal."
                },
                "value": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Retently customer property value to compare."
                }
              },
              "additionalProperties": false,
              "required": [
                "name",
                "op",
                "value"
              ],
              "description": "A Retently customer attribute filter."
            },
            "description": "Retently customer property filters.",
            "minItems": 1
          },
          "match": {
            "type": "string",
            "enum": [
              "all",
              "any"
            ],
            "description": "How Retently should combine multiple attribute filters."
          }
        },
        "additionalProperties": false,
        "description": "The input payload for listing Retently feedback responses."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "feedback": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "The raw object returned by Retently."
            },
            "description": "The feedback responses returned by Retently."
          },
          "pagination": {
            "type": "object",
            "properties": {
              "page": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The current page number returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pages": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of pages returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "limit": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The page size returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sort": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Retently sort value returned in the response."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "total": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of matching records returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "required": [
              "page",
              "pages",
              "limit",
              "sort",
              "total"
            ],
            "description": "Pagination metadata returned by Retently when present."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "feedback",
          "pagination",
          "raw"
        ],
        "description": "The response returned when listing Retently feedback."
      }
    },
    {
      "id": "retently.list_templates",
      "service": "retently",
      "name": "list_templates",
      "description": "List Retently survey templates.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "The input payload for listing Retently templates."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "templates": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "The raw object returned by Retently."
            },
            "description": "The survey templates returned by Retently."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "templates",
          "raw"
        ],
        "description": "The response returned when listing Retently templates."
      }
    },
    {
      "id": "retently.upsert_customers",
      "service": "retently",
      "name": "upsert_customers",
      "description": "Create or update Retently customers in bulk, including tags, properties, and fields to unset.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "subscribers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "email": {
                  "type": "string",
                  "description": "The customer's email address.",
                  "format": "email"
                },
                "first_name": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The customer's first name."
                },
                "last_name": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The customer's last name."
                },
                "company": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The customer's company name."
                },
                "tags": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "description": "A Retently customer tag."
                  },
                  "description": "Retently tags to assign to the customer.",
                  "minItems": 1
                },
                "properties": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "type": "string",
                        "minLength": 1,
                        "description": "The display label for the Retently customer property."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "string",
                          "date",
                          "integer",
                          "collection",
                          "boolean"
                        ],
                        "description": "The Retently customer property type."
                      },
                      "value": {
                        "description": "The value to store for this Retently customer property."
                      },
                      "name": {
                        "type": "string",
                        "minLength": 1,
                        "description": "The internal Retently customer property name."
                      }
                    },
                    "additionalProperties": false,
                    "required": [
                      "label",
                      "type",
                      "value"
                    ],
                    "description": "A Retently customer property to create or update."
                  },
                  "description": "Retently customer properties to create or update.",
                  "minItems": 1
                },
                "unset_properties": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "description": "A Retently property name or label to remove."
                  },
                  "description": "Retently property names or labels to remove from the customer.",
                  "minItems": 1
                },
                "unset_tags": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "description": "A Retently tag to remove."
                  },
                  "description": "Retently tag names to remove from the customer.",
                  "minItems": 1
                }
              },
              "additionalProperties": false,
              "required": [
                "email"
              ],
              "description": "A Retently customer to create or update."
            },
            "description": "Retently customers to create or update.",
            "minItems": 1,
            "maxItems": 1000
          }
        },
        "additionalProperties": false,
        "required": [
          "subscribers"
        ],
        "description": "The input payload for creating or updating Retently customers."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "customers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "The raw object returned by Retently."
            },
            "description": "The customers returned by Retently."
          },
          "pagination": {
            "type": "object",
            "properties": {
              "page": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The current page number returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pages": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of pages returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "limit": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The page size returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sort": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Retently sort value returned in the response."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "total": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of matching records returned by Retently."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "required": [
              "page",
              "pages",
              "limit",
              "sort",
              "total"
            ],
            "description": "Pagination metadata returned by Retently when present."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Retently."
          }
        },
        "additionalProperties": false,
        "required": [
          "customers",
          "pagination",
          "raw"
        ],
        "description": "The response returned when creating or updating Retently customers."
      }
    }
  ]
}
