from __future__ import annotations import base64 import json import re from pathlib import Path from typing import Any import httpx from a2a_pack.deepagents import create_a2a_deep_agent from langchain_core.messages import BaseMessage from langchain_core.tools import StructuredTool from pydantic import BaseModel, Field from a2a_pack import ( A2AAgent, ConsumerSetup, ConsumerSetupField, ConsumerSetupMissing, EgressPolicy, LLMProvisioning, Pricing, Resources, RunContext, skill, ) DEFAULT_BASE_URL = "https://api.resend.com" OPERATIONS = json.loads("{\n \"delete_api_keys_api_key_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing API key\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_api_keys_api_key_id\",\n \"parameters\": [\n {\n \"description\": \"The API key ID.\",\n \"in\": \"path\",\n \"name\": \"api_key_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/api-keys/{api_key_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_api_keys_api_key_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing API key\",\n \"tags\": [\n \"API keys\"\n ]\n },\n \"delete_audiences_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Deprecated: Use Segments instead. These endpoints still work, but will be removed in the future.\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_audiences_id\",\n \"parameters\": [\n {\n \"description\": \"The Audience ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/audiences/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_audiences_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing audience\",\n \"tags\": [\n \"Audiences\"\n ]\n },\n \"delete_automations_automation_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Delete an automation\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_automations_automation_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_automations_automation_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Delete an automation\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"delete_broadcasts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing broadcast that is in the draft status\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_broadcasts_id\",\n \"parameters\": [\n {\n \"description\": \"The Broadcast ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/broadcasts/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_broadcasts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing broadcast that is in the draft status\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"delete_contact_properties_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing contact property\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_contact_properties_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact Property ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contact-properties/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_contact_properties_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing contact property\",\n \"tags\": [\n \"Contact Properties\"\n ]\n },\n \"delete_contacts_contact_id_segments_segment_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove a contact from a segment\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_contacts_contact_id_segments_segment_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"contact_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"The Segment ID.\",\n \"in\": \"path\",\n \"name\": \"segment_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{contact_id}/segments/{segment_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_contacts_contact_id_segments_segment_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove a contact from a segment\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"delete_contacts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing contact by ID or email\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_contacts_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_contacts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing contact by ID or email\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"delete_domains_domain_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing domain\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_domains_domain_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the domain.\",\n \"in\": \"path\",\n \"name\": \"domain_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/domains/{domain_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_domains_domain_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing domain\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"delete_events_identifier\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Delete an event\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_events_identifier\",\n \"parameters\": [\n {\n \"description\": \"The event ID (UUID) or event name.\",\n \"in\": \"path\",\n \"name\": \"identifier\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/events/{identifier}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_events_identifier\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Delete an event\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"delete_segments_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing segment\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_segments_id\",\n \"parameters\": [\n {\n \"description\": \"The Segment ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/segments/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_segments_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing segment\",\n \"tags\": [\n \"Segments\"\n ]\n },\n \"delete_templates_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing template\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_templates_id\",\n \"parameters\": [\n {\n \"description\": \"The Template ID or alias.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_templates_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"delete_topics_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing topic\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_topics_id\",\n \"parameters\": [\n {\n \"description\": \"The Topic ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/topics/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_topics_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing topic\",\n \"tags\": [\n \"Topics\"\n ]\n },\n \"delete_webhooks_webhook_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Remove an existing webhook\",\n \"destructive\": true,\n \"method\": \"DELETE\",\n \"operation_id\": \"delete_webhooks_webhook_id\",\n \"parameters\": [\n {\n \"description\": \"The Webhook ID.\",\n \"in\": \"path\",\n \"name\": \"webhook_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/webhooks/{webhook_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"delete_webhooks_webhook_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Remove an existing webhook\",\n \"tags\": [\n \"Webhooks\"\n ]\n },\n \"get_api_keys\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of API keys\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_api_keys\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/api-keys\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_api_keys\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of API keys\",\n \"tags\": [\n \"API keys\"\n ]\n },\n \"get_audiences\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Deprecated: Use Segments instead. These endpoints still work, but will be removed in the future.\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_audiences\",\n \"parameters\": [],\n \"path\": \"/audiences\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_audiences\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of audiences\",\n \"tags\": [\n \"Audiences\"\n ]\n },\n \"get_audiences_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Deprecated: Use Segments instead. These endpoints still work, but will be removed in the future.\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_audiences_id\",\n \"parameters\": [\n {\n \"description\": \"The Audience ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/audiences/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_audiences_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single audience\",\n \"tags\": [\n \"Audiences\"\n ]\n },\n \"get_automations\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of automations\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_automations\",\n \"parameters\": [\n {\n \"description\": \"Filter automations by status.\",\n \"in\": \"query\",\n \"name\": \"status\",\n \"required\": false,\n \"schema\": {\n \"enum\": [\n \"enabled\",\n \"disabled\"\n ],\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_automations\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of automations\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"get_automations_automation_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single automation\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_automations_automation_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_automations_automation_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single automation\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"get_automations_automation_id_runs\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of automation runs\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_automations_automation_id_runs\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Filter runs by status. Comma-separated list of: running, completed, failed, cancelled.\",\n \"in\": \"query\",\n \"name\": \"status\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}/runs\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_automations_automation_id_runs\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of automation runs\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"get_automations_automation_id_runs_run_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single automation run\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_automations_automation_id_runs_run_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"The ID of the automation run.\",\n \"in\": \"path\",\n \"name\": \"run_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}/runs/{run_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_automations_automation_id_runs_run_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single automation run\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"get_broadcasts\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of broadcasts\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_broadcasts\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/broadcasts\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_broadcasts\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of broadcasts\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"get_broadcasts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single broadcast\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_broadcasts_id\",\n \"parameters\": [\n {\n \"description\": \"The Broadcast ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/broadcasts/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_broadcasts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single broadcast\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"get_contact_properties\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of contact properties\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contact_properties\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contact-properties\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contact_properties\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of contact properties\",\n \"tags\": [\n \"Contact Properties\"\n ]\n },\n \"get_contact_properties_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single contact property\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contact_properties_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact Property ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contact-properties/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contact_properties_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single contact property\",\n \"tags\": [\n \"Contact Properties\"\n ]\n },\n \"get_contacts\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of contacts\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contacts\",\n \"parameters\": [\n {\n \"description\": \"Filter contacts by segment ID.\",\n \"in\": \"query\",\n \"name\": \"segment_id\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contacts\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of contacts\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"get_contacts_contact_id_segments\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of segments for a contact\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contacts_contact_id_segments\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"contact_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{contact_id}/segments\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contacts_contact_id_segments\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of segments for a contact\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"get_contacts_contact_id_topics\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve topics for a contact\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contacts_contact_id_topics\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"contact_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{contact_id}/topics\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contacts_contact_id_topics\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve topics for a contact\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"get_contacts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single contact by ID or email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_contacts_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_contacts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single contact by ID or email\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"get_domains\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of domains\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_domains\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/domains\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_domains\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of domains\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"get_domains_domain_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single domain\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_domains_domain_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the domain.\",\n \"in\": \"path\",\n \"name\": \"domain_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/domains/{domain_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_domains_domain_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single domain\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"get_emails\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of emails\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of emails\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"get_emails_email_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_email_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/{email_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_email_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single email\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"get_emails_email_id_attachments\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of attachments for a sent email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_email_id_attachments\",\n \"parameters\": [\n {\n \"description\": \"The ID of the email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Maximum number of attachments to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results after this attachment ID. Cannot be used with 'before'.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results before this attachment ID. Cannot be used with 'after'.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/{email_id}/attachments\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_email_id_attachments\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of attachments for a sent email\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"get_emails_email_id_attachments_attachment_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single attachment for a sent email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_email_id_attachments_attachment_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"The ID of the attachment.\",\n \"in\": \"path\",\n \"name\": \"attachment_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/{email_id}/attachments/{attachment_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_email_id_attachments_attachment_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single attachment for a sent email\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"get_emails_receiving\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of received emails\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_receiving\",\n \"parameters\": [\n {\n \"description\": \"Maximum number of received emails to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results after this email ID. Cannot be used with 'before'.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results before this email ID. Cannot be used with 'after'.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/receiving\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_receiving\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of received emails\",\n \"tags\": [\n \"Receiving Emails\"\n ]\n },\n \"get_emails_receiving_email_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single received email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_receiving_email_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the received email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/receiving/{email_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_receiving_email_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single received email\",\n \"tags\": [\n \"Receiving Emails\"\n ]\n },\n \"get_emails_receiving_email_id_attachments\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of attachments for a received email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_receiving_email_id_attachments\",\n \"parameters\": [\n {\n \"description\": \"The ID of the received email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Maximum number of attachments to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results after this attachment ID. Cannot be used with 'before'.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results before this attachment ID. Cannot be used with 'after'.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/receiving/{email_id}/attachments\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_receiving_email_id_attachments\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of attachments for a received email\",\n \"tags\": [\n \"Receiving Emails\"\n ]\n },\n \"get_emails_receiving_email_id_attachments_attachment_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single attachment for a received email\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_emails_receiving_email_id_attachments_attachment_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the received email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"The ID of the attachment.\",\n \"in\": \"path\",\n \"name\": \"attachment_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/receiving/{email_id}/attachments/{attachment_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_emails_receiving_email_id_attachments_attachment_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single attachment for a received email\",\n \"tags\": [\n \"Receiving Emails\"\n ]\n },\n \"get_events\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of events\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_events\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/events\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_events\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of events\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"get_events_identifier\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single event\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_events_identifier\",\n \"parameters\": [\n {\n \"description\": \"The event ID (UUID) or event name.\",\n \"in\": \"path\",\n \"name\": \"identifier\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/events/{identifier}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_events_identifier\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single event\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"get_logs\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of logs\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_logs\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/logs\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_logs\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of logs\",\n \"tags\": [\n \"Logs\"\n ]\n },\n \"get_logs_log_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single log\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_logs_log_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the log.\",\n \"in\": \"path\",\n \"name\": \"log_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/logs/{log_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_logs_log_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single log\",\n \"tags\": [\n \"Logs\"\n ]\n },\n \"get_segments\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of segments\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_segments\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/segments\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_segments\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of segments\",\n \"tags\": [\n \"Segments\"\n ]\n },\n \"get_segments_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single segment\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_segments_id\",\n \"parameters\": [\n {\n \"description\": \"The Segment ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/segments/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_segments_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single segment\",\n \"tags\": [\n \"Segments\"\n ]\n },\n \"get_templates\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of templates\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_templates\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_templates\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of templates\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"get_templates_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single template\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_templates_id\",\n \"parameters\": [\n {\n \"description\": \"The Template ID or alias.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_templates_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"get_topics\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of topics\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_topics\",\n \"parameters\": [\n {\n \"description\": \"Number of items to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"maximum\": 100,\n \"minimum\": 1,\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Return items after this cursor.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Return items before this cursor.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/topics\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_topics\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of topics\",\n \"tags\": [\n \"Topics\"\n ]\n },\n \"get_topics_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single topic\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_topics_id\",\n \"parameters\": [\n {\n \"description\": \"The Topic ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/topics/{id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_topics_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single topic\",\n \"tags\": [\n \"Topics\"\n ]\n },\n \"get_webhooks\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a list of webhooks\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_webhooks\",\n \"parameters\": [\n {\n \"description\": \"Maximum number of webhooks to return.\",\n \"in\": \"query\",\n \"name\": \"limit\",\n \"required\": false,\n \"schema\": {\n \"type\": \"integer\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results after this webhook ID. Cannot be used with 'before'.\",\n \"in\": \"query\",\n \"name\": \"after\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"Pagination cursor to fetch results before this webhook ID. Cannot be used with 'after'.\",\n \"in\": \"query\",\n \"name\": \"before\",\n \"required\": false,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/webhooks\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_webhooks\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a list of webhooks\",\n \"tags\": [\n \"Webhooks\"\n ]\n },\n \"get_webhooks_webhook_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Retrieve a single webhook\",\n \"destructive\": false,\n \"method\": \"GET\",\n \"operation_id\": \"get_webhooks_webhook_id\",\n \"parameters\": [\n {\n \"description\": \"The Webhook ID.\",\n \"in\": \"path\",\n \"name\": \"webhook_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/webhooks/{webhook_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"get_webhooks_webhook_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Retrieve a single webhook\",\n \"tags\": [\n \"Webhooks\"\n ]\n },\n \"patch_automations_automation_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an automation\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_automations_automation_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/PatchAutomationRequest\"\n },\n \"security\": null,\n \"skill_name\": \"patch_automations_automation_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an automation\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"patch_broadcasts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing broadcast\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_broadcasts_id\",\n \"parameters\": [\n {\n \"description\": \"The Broadcast ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/broadcasts/{id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateBroadcastOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_broadcasts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing broadcast\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"patch_contact_properties_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing contact property\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_contact_properties_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact Property ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contact-properties/{id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateContactPropertyOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_contact_properties_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing contact property\",\n \"tags\": [\n \"Contact Properties\"\n ]\n },\n \"patch_contacts_contact_id_topics\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update topics for a contact\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_contacts_contact_id_topics\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"contact_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{contact_id}/topics\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateContactTopicsOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_contacts_contact_id_topics\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update topics for a contact\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"patch_contacts_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update a single contact by ID or email\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_contacts_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateContactOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_contacts_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update a single contact by ID or email\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"patch_domains_domain_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing domain\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_domains_domain_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the domain.\",\n \"in\": \"path\",\n \"name\": \"domain_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/domains/{domain_id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateDomainOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_domains_domain_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing domain\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"patch_emails_email_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update a single email\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_emails_email_id\",\n \"parameters\": [\n {\n \"description\": \"The ID of the email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/{email_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"patch_emails_email_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update a single email\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"patch_events_identifier\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an event\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_events_identifier\",\n \"parameters\": [\n {\n \"description\": \"The event ID (UUID) or event name.\",\n \"in\": \"path\",\n \"name\": \"identifier\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/events/{identifier}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateEventRequest\"\n },\n \"security\": null,\n \"skill_name\": \"patch_events_identifier\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an event\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"patch_templates_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing template\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_templates_id\",\n \"parameters\": [\n {\n \"description\": \"The Template ID or alias.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates/{id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateTemplateOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_templates_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"patch_topics_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing topic\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_topics_id\",\n \"parameters\": [\n {\n \"description\": \"The Topic ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/topics/{id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateTopicOptions\"\n },\n \"security\": null,\n \"skill_name\": \"patch_topics_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing topic\",\n \"tags\": [\n \"Topics\"\n ]\n },\n \"patch_webhooks_webhook_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Update an existing webhook\",\n \"destructive\": true,\n \"method\": \"PATCH\",\n \"operation_id\": \"patch_webhooks_webhook_id\",\n \"parameters\": [\n {\n \"description\": \"The Webhook ID.\",\n \"in\": \"path\",\n \"name\": \"webhook_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/webhooks/{webhook_id}\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/UpdateWebhookRequest\"\n },\n \"security\": null,\n \"skill_name\": \"patch_webhooks_webhook_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Update an existing webhook\",\n \"tags\": [\n \"Webhooks\"\n ]\n },\n \"post_api_keys\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new API key\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_api_keys\",\n \"parameters\": [],\n \"path\": \"/api-keys\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateApiKeyRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_api_keys\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new API key\",\n \"tags\": [\n \"API keys\"\n ]\n },\n \"post_audiences\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Deprecated: Use Segments instead. These endpoints still work, but will be removed in the future.\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_audiences\",\n \"parameters\": [],\n \"path\": \"/audiences\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateAudienceOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_audiences\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a list of contacts\",\n \"tags\": [\n \"Audiences\"\n ]\n },\n \"post_automations\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create an automation\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_automations\",\n \"parameters\": [],\n \"path\": \"/automations\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateAutomationRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_automations\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create an automation\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"post_automations_automation_id_stop\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Stop an automation\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_automations_automation_id_stop\",\n \"parameters\": [\n {\n \"description\": \"The ID of the automation.\",\n \"in\": \"path\",\n \"name\": \"automation_id\",\n \"required\": true,\n \"schema\": {\n \"format\": \"uuid\",\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/automations/{automation_id}/stop\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_automations_automation_id_stop\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Stop an automation\",\n \"tags\": [\n \"Automations\"\n ]\n },\n \"post_broadcasts\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a broadcast\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_broadcasts\",\n \"parameters\": [],\n \"path\": \"/broadcasts\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateBroadcastOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_broadcasts\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a broadcast\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"post_broadcasts_id_send\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Send or schedule a broadcast\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_broadcasts_id_send\",\n \"parameters\": [\n {\n \"description\": \"The Broadcast ID.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/broadcasts/{id}/send\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/SendBroadcastOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_broadcasts_id_send\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Send or schedule a broadcast\",\n \"tags\": [\n \"Broadcasts\"\n ]\n },\n \"post_contact_properties\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new contact property\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_contact_properties\",\n \"parameters\": [],\n \"path\": \"/contact-properties\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateContactPropertyOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_contact_properties\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new contact property\",\n \"tags\": [\n \"Contact Properties\"\n ]\n },\n \"post_contacts\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new contact\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_contacts\",\n \"parameters\": [],\n \"path\": \"/contacts\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateContactOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_contacts\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new contact\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"post_contacts_contact_id_segments_segment_id\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Add a contact to a segment\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_contacts_contact_id_segments_segment_id\",\n \"parameters\": [\n {\n \"description\": \"The Contact ID or email address.\",\n \"in\": \"path\",\n \"name\": \"contact_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n },\n {\n \"description\": \"The Segment ID.\",\n \"in\": \"path\",\n \"name\": \"segment_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/contacts/{contact_id}/segments/{segment_id}\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_contacts_contact_id_segments_segment_id\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Add a contact to a segment\",\n \"tags\": [\n \"Contacts\"\n ]\n },\n \"post_domains\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new domain\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_domains\",\n \"parameters\": [],\n \"path\": \"/domains\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateDomainRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_domains\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new domain\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"post_domains_domain_id_verify\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Triggers verification of the domain's DNS records including DKIM, SPF, and the tracking CNAME (if a tracking subdomain is configured).\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_domains_domain_id_verify\",\n \"parameters\": [\n {\n \"description\": \"The ID of the domain.\",\n \"in\": \"path\",\n \"name\": \"domain_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/domains/{domain_id}/verify\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_domains_domain_id_verify\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Verify an existing domain\",\n \"tags\": [\n \"Domains\"\n ]\n },\n \"post_emails\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Send an email\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_emails\",\n \"parameters\": [\n {\n \"description\": \"A unique identifier for the request to ensure emails are only sent once. [Learn more](https://resend.com/docs/dashboard/emails/idempotency-keys)\",\n \"in\": \"header\",\n \"name\": \"Idempotency-Key\",\n \"required\": false,\n \"schema\": {\n \"maxLength\": 256,\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/SendEmailRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_emails\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Send an email\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"post_emails_batch\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Trigger up to 100 batch emails at once.\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_emails_batch\",\n \"parameters\": [\n {\n \"description\": \"A unique identifier for the request to ensure emails are only sent once. [Learn more](https://resend.com/docs/dashboard/emails/idempotency-keys)\",\n \"in\": \"header\",\n \"name\": \"Idempotency-Key\",\n \"required\": false,\n \"schema\": {\n \"maxLength\": 256,\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/batch\",\n \"request_body\": {\n \"items\": {\n \"$ref\": \"#/components/schemas/SendEmailRequest\"\n },\n \"type\": \"array\"\n },\n \"security\": null,\n \"skill_name\": \"post_emails_batch\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Trigger up to 100 batch emails at once.\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"post_emails_email_id_cancel\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Cancel the schedule of the e-mail.\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_emails_email_id_cancel\",\n \"parameters\": [\n {\n \"description\": \"The ID of the email.\",\n \"in\": \"path\",\n \"name\": \"email_id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/emails/{email_id}/cancel\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_emails_email_id_cancel\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Cancel the schedule of the e-mail.\",\n \"tags\": [\n \"Emails\"\n ]\n },\n \"post_events\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create an event\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_events\",\n \"parameters\": [],\n \"path\": \"/events\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateEventRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_events\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create an event\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"post_events_send\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Send an event\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_events_send\",\n \"parameters\": [],\n \"path\": \"/events/send\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/SendEventRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_events_send\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Send an event\",\n \"tags\": [\n \"Events\"\n ]\n },\n \"post_segments\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new segment\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_segments\",\n \"parameters\": [],\n \"path\": \"/segments\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateSegmentOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_segments\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new segment\",\n \"tags\": [\n \"Segments\"\n ]\n },\n \"post_templates\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a template\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_templates\",\n \"parameters\": [],\n \"path\": \"/templates\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateTemplateRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_templates\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"post_templates_id_duplicate\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Duplicate a template\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_templates_id_duplicate\",\n \"parameters\": [\n {\n \"description\": \"The Template ID or alias.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates/{id}/duplicate\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_templates_id_duplicate\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Duplicate a template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"post_templates_id_publish\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Publish a template\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_templates_id_publish\",\n \"parameters\": [\n {\n \"description\": \"The Template ID or alias.\",\n \"in\": \"path\",\n \"name\": \"id\",\n \"required\": true,\n \"schema\": {\n \"type\": \"string\"\n }\n }\n ],\n \"path\": \"/templates/{id}/publish\",\n \"request_body\": null,\n \"security\": null,\n \"skill_name\": \"post_templates_id_publish\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Publish a template\",\n \"tags\": [\n \"Templates\"\n ]\n },\n \"post_topics\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new topic\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_topics\",\n \"parameters\": [],\n \"path\": \"/topics\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateTopicOptions\"\n },\n \"security\": null,\n \"skill_name\": \"post_topics\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new topic\",\n \"tags\": [\n \"Topics\"\n ]\n },\n \"post_webhooks\": {\n \"base_url\": \"https://api.resend.com\",\n \"base_url_field\": \"OPENAPI_BASE_URL\",\n \"description\": \"Create a new webhook\",\n \"destructive\": true,\n \"method\": \"POST\",\n \"operation_id\": \"post_webhooks\",\n \"parameters\": [],\n \"path\": \"/webhooks\",\n \"request_body\": {\n \"$ref\": \"#/components/schemas/CreateWebhookRequest\"\n },\n \"security\": null,\n \"skill_name\": \"post_webhooks\",\n \"source_index\": 1,\n \"source_openapi_url\": \"https://resend.com/openapi.json\",\n \"source_title\": \"Resend\",\n \"summary\": \"Create a new webhook\",\n \"tags\": [\n \"Webhooks\"\n ]\n }\n}") OPERATION_GROUPS = json.loads("[\n {\n \"common_prefix\": \"/emails\",\n \"description\": \"Handle 12 OpenAPI operation(s) under /emails for the emails route group.\",\n \"id\": \"emails\",\n \"label\": \"emails\",\n \"operation_ids\": [\n \"post_emails\",\n \"get_emails\",\n \"get_emails_email_id\",\n \"patch_emails_email_id\",\n \"post_emails_email_id_cancel\",\n \"post_emails_batch\",\n \"get_emails_email_id_attachments\",\n \"get_emails_email_id_attachments_attachment_id\",\n \"get_emails_receiving\",\n \"get_emails_receiving_email_id\",\n \"get_emails_receiving_email_id_attachments\",\n \"get_emails_receiving_email_id_attachments_attachment_id\"\n ],\n \"skill_dir\": \"emails\",\n \"skill_name\": \"emails-routes\",\n \"skill_path\": \"skills/emails/SKILL.md\",\n \"subagent_name\": \"emails-api\"\n },\n {\n \"common_prefix\": \"/domains\",\n \"description\": \"Handle 6 OpenAPI operation(s) under /domains for the domains route group.\",\n \"id\": \"domains\",\n \"label\": \"domains\",\n \"operation_ids\": [\n \"post_domains\",\n \"get_domains\",\n \"get_domains_domain_id\",\n \"patch_domains_domain_id\",\n \"delete_domains_domain_id\",\n \"post_domains_domain_id_verify\"\n ],\n \"skill_dir\": \"domains\",\n \"skill_name\": \"domains-routes\",\n \"skill_path\": \"skills/domains/SKILL.md\",\n \"subagent_name\": \"domains-api\"\n },\n {\n \"common_prefix\": \"/api-keys\",\n \"description\": \"Handle 3 OpenAPI operation(s) under /api-keys for the api keys route group.\",\n \"id\": \"api_keys\",\n \"label\": \"api keys\",\n \"operation_ids\": [\n \"post_api_keys\",\n \"get_api_keys\",\n \"delete_api_keys_api_key_id\"\n ],\n \"skill_dir\": \"api-keys\",\n \"skill_name\": \"api-keys-routes\",\n \"skill_path\": \"skills/api-keys/SKILL.md\",\n \"subagent_name\": \"api-keys-api\"\n },\n {\n \"common_prefix\": \"/templates\",\n \"description\": \"Handle 7 OpenAPI operation(s) under /templates for the templates route group.\",\n \"id\": \"templates\",\n \"label\": \"templates\",\n \"operation_ids\": [\n \"post_templates\",\n \"get_templates\",\n \"get_templates_id\",\n \"patch_templates_id\",\n \"delete_templates_id\",\n \"post_templates_id_publish\",\n \"post_templates_id_duplicate\"\n ],\n \"skill_dir\": \"templates\",\n \"skill_name\": \"templates-routes\",\n \"skill_path\": \"skills/templates/SKILL.md\",\n \"subagent_name\": \"templates-api\"\n },\n {\n \"common_prefix\": \"/audiences\",\n \"description\": \"Handle 4 OpenAPI operation(s) under /audiences for the audiences route group.\",\n \"id\": \"audiences\",\n \"label\": \"audiences\",\n \"operation_ids\": [\n \"post_audiences\",\n \"get_audiences\",\n \"delete_audiences_id\",\n \"get_audiences_id\"\n ],\n \"skill_dir\": \"audiences\",\n \"skill_name\": \"audiences-routes\",\n \"skill_path\": \"skills/audiences/SKILL.md\",\n \"subagent_name\": \"audiences-api\"\n },\n {\n \"common_prefix\": \"/contacts\",\n \"description\": \"Handle 10 OpenAPI operation(s) under /contacts for the contacts route group.\",\n \"id\": \"contacts\",\n \"label\": \"contacts\",\n \"operation_ids\": [\n \"post_contacts\",\n \"get_contacts\",\n \"get_contacts_id\",\n \"patch_contacts_id\",\n \"delete_contacts_id\",\n \"get_contacts_contact_id_segments\",\n \"post_contacts_contact_id_segments_segment_id\",\n \"delete_contacts_contact_id_segments_segment_id\",\n \"get_contacts_contact_id_topics\",\n \"patch_contacts_contact_id_topics\"\n ],\n \"skill_dir\": \"contacts\",\n \"skill_name\": \"contacts-routes\",\n \"skill_path\": \"skills/contacts/SKILL.md\",\n \"subagent_name\": \"contacts-api\"\n },\n {\n \"common_prefix\": \"/broadcasts\",\n \"description\": \"Handle 6 OpenAPI operation(s) under /broadcasts for the broadcasts route group.\",\n \"id\": \"broadcasts\",\n \"label\": \"broadcasts\",\n \"operation_ids\": [\n \"post_broadcasts\",\n \"get_broadcasts\",\n \"delete_broadcasts_id\",\n \"get_broadcasts_id\",\n \"patch_broadcasts_id\",\n \"post_broadcasts_id_send\"\n ],\n \"skill_dir\": \"broadcasts\",\n \"skill_name\": \"broadcasts-routes\",\n \"skill_path\": \"skills/broadcasts/SKILL.md\",\n \"subagent_name\": \"broadcasts-api\"\n },\n {\n \"common_prefix\": \"/webhooks\",\n \"description\": \"Handle 5 OpenAPI operation(s) under /webhooks for the webhooks route group.\",\n \"id\": \"webhooks\",\n \"label\": \"webhooks\",\n \"operation_ids\": [\n \"post_webhooks\",\n \"get_webhooks\",\n \"get_webhooks_webhook_id\",\n \"patch_webhooks_webhook_id\",\n \"delete_webhooks_webhook_id\"\n ],\n \"skill_dir\": \"webhooks\",\n \"skill_name\": \"webhooks-routes\",\n \"skill_path\": \"skills/webhooks/SKILL.md\",\n \"subagent_name\": \"webhooks-api\"\n },\n {\n \"common_prefix\": \"/segments\",\n \"description\": \"Handle 4 OpenAPI operation(s) under /segments for the segments route group.\",\n \"id\": \"segments\",\n \"label\": \"segments\",\n \"operation_ids\": [\n \"post_segments\",\n \"get_segments\",\n \"get_segments_id\",\n \"delete_segments_id\"\n ],\n \"skill_dir\": \"segments\",\n \"skill_name\": \"segments-routes\",\n \"skill_path\": \"skills/segments/SKILL.md\",\n \"subagent_name\": \"segments-api\"\n },\n {\n \"common_prefix\": \"/topics\",\n \"description\": \"Handle 5 OpenAPI operation(s) under /topics for the topics route group.\",\n \"id\": \"topics\",\n \"label\": \"topics\",\n \"operation_ids\": [\n \"post_topics\",\n \"get_topics\",\n \"get_topics_id\",\n \"patch_topics_id\",\n \"delete_topics_id\"\n ],\n \"skill_dir\": \"topics\",\n \"skill_name\": \"topics-routes\",\n \"skill_path\": \"skills/topics/SKILL.md\",\n \"subagent_name\": \"topics-api\"\n },\n {\n \"common_prefix\": \"/contact-properties\",\n \"description\": \"Handle 5 OpenAPI operation(s) under /contact-properties for the contact properties route group.\",\n \"id\": \"contact_properties\",\n \"label\": \"contact properties\",\n \"operation_ids\": [\n \"post_contact_properties\",\n \"get_contact_properties\",\n \"get_contact_properties_id\",\n \"patch_contact_properties_id\",\n \"delete_contact_properties_id\"\n ],\n \"skill_dir\": \"contact-properties\",\n \"skill_name\": \"contact-properties-routes\",\n \"skill_path\": \"skills/contact-properties/SKILL.md\",\n \"subagent_name\": \"contact-properties-api\"\n },\n {\n \"common_prefix\": \"/logs\",\n \"description\": \"Handle 2 OpenAPI operation(s) under /logs for the logs route group.\",\n \"id\": \"logs\",\n \"label\": \"logs\",\n \"operation_ids\": [\n \"get_logs\",\n \"get_logs_log_id\"\n ],\n \"skill_dir\": \"logs\",\n \"skill_name\": \"logs-routes\",\n \"skill_path\": \"skills/logs/SKILL.md\",\n \"subagent_name\": \"logs-api\"\n },\n {\n \"common_prefix\": \"/automations\",\n \"description\": \"Handle 8 OpenAPI operation(s) under /automations for the automations route group.\",\n \"id\": \"automations\",\n \"label\": \"automations\",\n \"operation_ids\": [\n \"post_automations\",\n \"get_automations\",\n \"get_automations_automation_id\",\n \"patch_automations_automation_id\",\n \"delete_automations_automation_id\",\n \"post_automations_automation_id_stop\",\n \"get_automations_automation_id_runs\",\n \"get_automations_automation_id_runs_run_id\"\n ],\n \"skill_dir\": \"automations\",\n \"skill_name\": \"automations-routes\",\n \"skill_path\": \"skills/automations/SKILL.md\",\n \"subagent_name\": \"automations-api\"\n },\n {\n \"common_prefix\": \"/events\",\n \"description\": \"Handle 6 OpenAPI operation(s) under /events for the events route group.\",\n \"id\": \"events\",\n \"label\": \"events\",\n \"operation_ids\": [\n \"post_events\",\n \"get_events\",\n \"post_events_send\",\n \"get_events_identifier\",\n \"patch_events_identifier\",\n \"delete_events_identifier\"\n ],\n \"skill_dir\": \"events\",\n \"skill_name\": \"events-routes\",\n \"skill_path\": \"skills/events/SKILL.md\",\n \"subagent_name\": \"events-api\"\n }\n]") ROOT_SECURITY = json.loads("[\n {\n \"bearerAuth\": []\n }\n]") SECURITY_SCHEMES = json.loads("{\n \"bearerAuth\": {\n \"scheme\": \"bearer\",\n \"type\": \"http\"\n }\n}") SECURITY_FIELDS = json.loads("{\n \"bearerAuth\": {\n \"field\": \"BEARERAUTH_TOKEN\",\n \"kind\": \"http\",\n \"scheme\": \"bearer\"\n }\n}") PATH_PARAMETER_RE = re.compile(r"{([^}/]+)}") SOURCE_ROOT = Path(globals().get("__file__", "agent.py")).resolve().parent SOURCE_SKILLS_DIR = SOURCE_ROOT / "skills" RUNTIME_SKILLS_DIR = ".deepagents/openapi-skills/" class OperationInput(BaseModel): parameters: dict[str, Any] = Field( default_factory=dict, description="Path, query, header, and cookie parameters keyed by OpenAPI parameter name.", ) body: Any | None = Field(default=None, description="JSON request body, when the operation accepts one.") class ResendOpenapiAgent(A2AAgent): name = "resend-openapi-agent" description = "Transactional email API for sends, domains, audiences, contacts, receiving, and webhooks." version = "1.5.0" consumer_setup = ConsumerSetup.from_fields( ConsumerSetupField.config("OPENAPI_BASE_URL", label="API base URL", description="Override the default API server (https://api.resend.com).", required=False, input_type="url"), ConsumerSetupField.secret("BEARERAUTH_TOKEN", label="bearerAuth bearer credential", description="Bearer token.", required=True), ) llm_provisioning = LLMProvisioning.PLATFORM pricing = Pricing( price_per_call_usd=0.0, caller_pays_llm=True, notes="Uses the caller's saved LLM credential through ctx.llm.", ) resources = Resources(cpu="200m", memory="512Mi") egress = EgressPolicy( allow_hosts=('api.resend.com',), deny_internet_by_default=True, ) tools_used = ("openapi", "deepagents") capabilities = { "openapi_auto_agent": { "operation_count": len(OPERATIONS), "default_base_url": DEFAULT_BASE_URL, "source_openapi_url": 'https://resend.com/openapi.json', "source_openapi_urls": ['https://resend.com/openapi.json'], "server_urls": ['https://api.resend.com'], "regenerable": True, "security_schemes": list(SECURITY_SCHEMES), } } @skill( name="auto", description="Use the OpenAPI service to complete a natural-language goal.", tags=("openapi", "auto"), timeout_seconds=900, ) async def auto(self, ctx: RunContext, goal: str) -> dict[str, Any]: creds = ctx.llm if not creds.api_key: return { "error": "llm_credentials_missing", "final": ( "LLM key required. Add an LLM credential in Settings > " "LLM credentials before running this agent." ), "messages": [], } backend = ctx.workspace_backend() skills_root = _seed_runtime_skills(backend, ctx) graph = create_a2a_deep_agent( ctx, creds=creds, backend=backend, tools=[], subagents=self._operation_subagents(ctx, skills_root), system_prompt=self._system_prompt(), ) result = await graph.ainvoke({"messages": [{"role": "user", "content": goal}]}) messages = result.get("messages", []) if isinstance(result, dict) else [] final = _message_text(messages[-1]) if messages else result return { "final": final, "messages": [_message_to_dict(message) for message in messages[-8:]], } def _operation_subagents(self, ctx: RunContext, skills_root: str) -> list[dict[str, Any]]: subagents: list[dict[str, Any]] = [] for group in OPERATION_GROUPS: skill_path = ( f"{skills_root}{group['skill_dir']}/" if skills_root else "" ) subagent = { "name": group["subagent_name"], "description": group["description"], "system_prompt": self._subagent_prompt(group), "tools": self._operation_tools(ctx, set(group["operation_ids"])), } if skill_path: subagent["skills"] = [skill_path] subagents.append(subagent) return subagents def _operation_tools( self, ctx: RunContext, operation_ids: set[str] | None = None, ) -> list[StructuredTool]: tools: list[StructuredTool] = [] for operation_id, operation in OPERATIONS.items(): if operation_ids is not None and operation_id not in operation_ids: continue async def call( parameters: dict[str, Any] | None = None, body: Any | None = None, *, _operation_id: str = operation_id, ) -> dict[str, Any]: return await self._request( ctx, _operation_id, parameters=parameters or {}, body=body, ) tools.append( StructuredTool.from_function( coroutine=call, name=operation["skill_name"], description=self._tool_description(operation), args_schema=OperationInput, ) ) return tools def _system_prompt(self) -> str: if OPERATION_GROUPS: lines = [ "You coordinate route-specific OpenAPI subagents.", "Delegate API work to the matching subagent with the task tool.", "Do not invent API responses; ask subagents to call their tools for real results.", "If a subagent reports missing consumer setup, tell the user which setup field is required.", "If a subagent reports that the generated OpenAPI agent may be stale, ask whether the user wants to refresh it from the latest OpenAPI spec.", "", "Available route groups:", ] for group in OPERATION_GROUPS: lines.append( f"- {group['subagent_name']}: {group['description']}" ) return "\n".join(lines) lines = [ "You operate an API through generated OpenAPI tools.", "Call tools to get real results. Do not invent API responses.", "For write, update, or delete operations, explain the intended action before calling the tool.", "If an operation reports missing consumer setup, tell the user which setup field is required.", "If an operation returns 404, 405, 410, or a schema/validation error that suggests the live API no longer matches these tools, tell the user this generated agent may need to be refreshed from the latest OpenAPI spec and ask whether they want to refresh it.", "", "Available operations:", ] for operation in OPERATIONS.values(): marker = "WRITE" if operation.get("destructive") else "READ" lines.append( f"- {operation['skill_name']}: {marker} {operation['method']} {operation['path']} — {operation['summary']}" ) return "\n".join(lines) def _subagent_prompt(self, group: dict[str, Any]) -> str: lines = [ "You operate one route group from a generated OpenAPI API.", "Use the available operation tools to make real API calls. Do not invent API responses.", "Read the route group's SKILL.md when it applies; it lists every route you cover.", "For write, update, or delete operations, explain the intended action before calling the tool.", "If an operation reports missing consumer setup, return the exact setup field name.", "If an operation returns 404, 405, 410, or a schema/validation error that suggests the live API no longer matches these tools, say the generated agent may need to be refreshed from the latest OpenAPI spec.", "", f"Route group: {group['label']}", f"Common prefix: {group.get('common_prefix') or '/'}", "Available operation tools:", ] for operation_id in group["operation_ids"]: operation = OPERATIONS[operation_id] marker = "WRITE" if operation.get("destructive") else "READ" lines.append( f"- {operation['skill_name']}: {marker} {operation['method']} {operation['path']} - {operation['summary']}" ) return "\n".join(lines) def _tool_description(self, operation: dict[str, Any]) -> str: parts = [ f"{operation['method']} {operation['path']}", str(operation.get("description") or operation.get("summary") or ""), ] if operation.get("parameters"): parts.append( "Parameters: " + ", ".join( f"{p['name']} in {p['in']}{' required' if p.get('required') else ''}" for p in operation["parameters"] ) ) if operation.get("request_body") is not None: parts.append("Accepts a JSON request body.") return "\n".join(part for part in parts if part) async def _request( self, ctx: RunContext, operation_id: str, *, parameters: dict[str, Any], body: Any | None, ) -> dict[str, Any]: operation = OPERATIONS[operation_id] default_base_url = str(operation.get("base_url") or DEFAULT_BASE_URL).rstrip("/") base_url_field = str(operation.get("base_url_field") or "OPENAPI_BASE_URL") base_url = str(ctx.consumer_config(base_url_field, default_base_url) or default_base_url).rstrip("/") url, query, headers = self._request_parts(ctx, operation, parameters) request_kwargs: dict[str, Any] = { "params": query, "headers": headers, } if body is not None: if isinstance(body, (bytes, bytearray)): body = body.decode("utf-8", errors="replace") if isinstance(body, str): stripped = body.strip() if stripped and stripped[0] in "{[": try: body = json.loads(stripped) except ValueError: pass request_kwargs["json"] = body async with httpx.AsyncClient(timeout=60.0, follow_redirects=True) as client: response = await client.request( operation["method"], f"{base_url}{url}", **request_kwargs, ) content_type = response.headers.get("content-type", "") try: payload: Any = response.json() if "json" in content_type else response.text except ValueError: payload = response.text if response.status_code >= 400: out = { "ok": False, "status_code": response.status_code, "operation_id": operation_id, "error": payload, } if response.status_code in {404, 405, 410, 422}: out["stale_openapi_hint"] = ( "This generated OpenAPI agent may be stale. Ask the user " "whether they want to refresh it from the latest OpenAPI spec." ) return out return { "ok": True, "status_code": response.status_code, "operation_id": operation_id, "result": payload, } def _request_parts( self, ctx: RunContext, operation: dict[str, Any], parameters: dict[str, Any], ) -> tuple[str, dict[str, Any], dict[str, str]]: path = operation["path"] query: dict[str, Any] = {} headers: dict[str, str] = {} cookies: dict[str, Any] = {} for param in operation.get("parameters") or []: name = param["name"] if name not in parameters: if param.get("required"): raise ValueError(f"missing required parameter {name!r}") continue value = parameters[name] location = param["in"] if location == "path": path = path.replace("{" + name + "}", str(value)) elif location == "query": query[name] = value elif location == "header": headers[name] = str(value) elif location == "cookie": cookies[name] = value unresolved = PATH_PARAMETER_RE.findall(path) if unresolved: missing = ", ".join(sorted(set(unresolved))) raise ValueError("missing required path parameter(s): " + missing) if cookies: headers["cookie"] = "; ".join(f"{key}={value}" for key, value in cookies.items()) auth_headers, auth_query = self._auth_for_operation(ctx, operation) headers.update(auth_headers) query.update(auth_query) return path, query, headers def _auth_for_operation(self, ctx: RunContext, operation: dict[str, Any]) -> tuple[dict[str, str], dict[str, Any]]: requirements = operation.get("security") if requirements is None: requirements = ROOT_SECURITY if requirements == []: return {}, {} missing: list[str] = [] for requirement in requirements or []: if not isinstance(requirement, dict) or not requirement: return {}, {} headers: dict[str, str] = {} query: dict[str, Any] = {} ok = True for scheme_name in requirement: mapping = SECURITY_FIELDS.get(scheme_name) or {} secret_name = mapping.get("field") value = _consumer_secret_optional(ctx, secret_name) if secret_name else "" if not value: ok = False if secret_name: missing.append(secret_name) continue kind = mapping.get("kind") if kind == "apiKey": prefix = mapping.get("prefix") or "" sent_value = f"{prefix}{value}" if mapping.get("location") == "query": query[mapping.get("name") or scheme_name] = sent_value else: headers[mapping.get("name") or scheme_name] = sent_value elif kind in {"http", "oauth2"}: scheme = mapping.get("scheme") or "Bearer" if scheme.lower() == "basic": token = base64.b64encode(value.encode("utf-8")).decode("ascii") headers["authorization"] = f"Basic {token}" else: headers["authorization"] = f"{scheme} {value}" else: ok = False if ok: return headers, query if missing: raise ConsumerSetupMissing( "operation requires consumer setup secret(s): " + ", ".join(sorted(set(missing))) ) return {}, {} def _consumer_secret_optional(ctx: RunContext, name: str | None) -> str: if not name: return "" try: return ctx.consumer_secret(name) except ConsumerSetupMissing: return "" def _runtime_skills_root(ctx: RunContext) -> str: workspace = getattr(ctx, "_workspace", None) prefixes = tuple(getattr(workspace, "write_prefixes", ()) or ()) if not prefixes: outputs_prefix = getattr(workspace, "outputs_prefix", None) prefixes = (outputs_prefix or "outputs/",) prefix = str(prefixes[0]).strip("/") return f"/{prefix}/{RUNTIME_SKILLS_DIR}" if prefix else f"/{RUNTIME_SKILLS_DIR}" def _seed_runtime_skills(backend: Any, ctx: RunContext) -> str: if not SOURCE_SKILLS_DIR.exists(): return "" runtime_root = _runtime_skills_root(ctx) uploads: list[tuple[str, bytes]] = [] for path in SOURCE_SKILLS_DIR.rglob("*"): if not path.is_file(): continue rel = path.relative_to(SOURCE_SKILLS_DIR).as_posix() uploads.append((runtime_root + rel, path.read_bytes())) if not uploads: return "" backend.upload_files(uploads) return runtime_root def _message_text(message: Any) -> Any: content = getattr(message, "content", message) return content def _message_to_dict(message: Any) -> dict[str, Any]: if isinstance(message, BaseMessage): return message.model_dump(mode="json") if hasattr(message, "model_dump"): return message.model_dump(mode="json") if isinstance(message, dict): return message return {"content": str(message)} agent = ResendOpenapiAgent()