{
  "service": "agora",
  "displayName": "Agora",
  "categories": [
    "Communication",
    "Developer Tools"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "Customer Secret",
      "placeholder": "AGORA_CUSTOMER_SECRET",
      "description": "Agora Customer Secret used as the Basic Auth password. View Customer ID and Customer Secret in the Agora Console RESTful API settings: https://console.agora.io/v2.",
      "extraFields": [
        {
          "key": "customerId",
          "label": "Customer ID",
          "inputType": "text",
          "required": true,
          "secret": false,
          "placeholder": "AGORA_CUSTOMER_ID",
          "description": "Agora Customer ID used as the Basic Auth username. View it with the Customer Secret in the Agora Console RESTful API settings: https://console.agora.io/v2."
        }
      ]
    }
  ],
  "homepageUrl": "https://www.agora.io",
  "actions": [
    {
      "id": "agora.create_project",
      "service": "agora",
      "name": "create_project",
      "description": "Create an Agora Console project.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The Agora Console project name."
          },
          "enableCertificate": {
            "type": "boolean",
            "description": "Whether to enable the primary App Certificate."
          }
        },
        "additionalProperties": false,
        "required": [
          "name"
        ],
        "description": "Input for creating an Agora Console project."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "description": "An Agora Console project ID."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora Console project name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "appId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora App ID for the project."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "recordingServer": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The recording server IP address when returned by Agora."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "created": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Unix timestamp in seconds when the project was created."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "A normalized Agora Console project."
          }
        },
        "additionalProperties": false,
        "description": "The normalized Agora project response."
      }
    },
    {
      "id": "agora.get_project",
      "service": "agora",
      "name": "get_project",
      "description": "Retrieve one Agora Console project by project ID and name.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "minLength": 1,
            "description": "An Agora Console project ID."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The Agora Console project name."
          }
        },
        "additionalProperties": false,
        "description": "Input for retrieving one Agora Console project."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "description": "An Agora Console project ID."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora Console project name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "appId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora App ID for the project."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "recordingServer": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The recording server IP address when returned by Agora."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "created": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Unix timestamp in seconds when the project was created."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "A normalized Agora Console project."
          }
        },
        "additionalProperties": false,
        "description": "The normalized Agora project response."
      }
    },
    {
      "id": "agora.get_project_usage",
      "service": "agora",
      "name": "get_project_usage",
      "description": "Retrieve usage data for one Agora Console project and business type.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "minLength": 1,
            "description": "An Agora Console project ID."
          },
          "fromDate": {
            "type": "string",
            "description": "The inclusive usage start date in YYYY-MM-DD format.",
            "format": "date"
          },
          "toDate": {
            "type": "string",
            "description": "The inclusive usage end date in YYYY-MM-DD format.",
            "format": "date"
          },
          "business": {
            "type": "string",
            "enum": [
              "default",
              "transcodeDuration",
              "recording",
              "cloudRecording",
              "miniapp"
            ],
            "description": "The Agora usage business type."
          }
        },
        "additionalProperties": false,
        "description": "Input for retrieving Agora project usage."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "meta": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Agora usage metadata keyed by metric name."
          },
          "usages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "date": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The usage date as an ISO timestamp or date string."
                    },
                    {
                      "type": "integer",
                      "description": "The usage date as a Unix timestamp when returned by Agora."
                    }
                  ],
                  "description": "The usage record date returned by Agora."
                },
                "usage": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The usage values keyed by Agora metric name."
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw usage record returned by Agora."
                }
              },
              "additionalProperties": false,
              "description": "A normalized Agora project usage record."
            },
            "description": "Usage records returned by Agora."
          }
        },
        "additionalProperties": false,
        "description": "The normalized Agora project usage response."
      }
    },
    {
      "id": "agora.list_projects",
      "service": "agora",
      "name": "list_projects",
      "description": "List Agora Console projects for the connected account.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "No input is required to list Agora projects."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "projects": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "minLength": 1,
                  "description": "An Agora Console project ID."
                },
                "name": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The Agora Console project name."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "appId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The Agora App ID for the project."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "recordingServer": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The recording server IP address when returned by Agora."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "status": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "created": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "description": "The Unix timestamp in seconds when the project was created."
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "additionalProperties": false,
              "description": "A normalized Agora Console project."
            },
            "description": "Projects returned by Agora."
          }
        },
        "additionalProperties": false,
        "description": "The normalized Agora project list response."
      }
    },
    {
      "id": "agora.reset_primary_certificate",
      "service": "agora",
      "name": "reset_primary_certificate",
      "description": "Reset the primary App Certificate for an Agora Console project.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "minLength": 1,
            "description": "An Agora Console project ID."
          }
        },
        "additionalProperties": false,
        "description": "Input for resetting an Agora primary App Certificate."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "description": "An Agora Console project ID."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora Console project name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "appId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora App ID for the project."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "recordingServer": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The recording server IP address when returned by Agora."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "created": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Unix timestamp in seconds when the project was created."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "A normalized Agora Console project."
          },
          "certificate": {
            "anyOf": [
              {
                "type": "string",
                "description": "The primary App Certificate returned by Agora."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": false,
        "description": "A normalized Agora certificate operation response."
      }
    },
    {
      "id": "agora.set_primary_certificate",
      "service": "agora",
      "name": "set_primary_certificate",
      "description": "Enable or disable the primary App Certificate for an Agora Console project.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "minLength": 1,
            "description": "An Agora Console project ID."
          },
          "enable": {
            "type": "boolean",
            "description": "Whether to enable the primary App Certificate."
          }
        },
        "additionalProperties": false,
        "description": "Input for setting an Agora primary App Certificate state."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "description": "An Agora Console project ID."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora Console project name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "appId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora App ID for the project."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "recordingServer": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The recording server IP address when returned by Agora."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "created": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Unix timestamp in seconds when the project was created."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "A normalized Agora Console project."
          },
          "certificate": {
            "anyOf": [
              {
                "type": "string",
                "description": "The primary App Certificate returned by Agora."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": false,
        "description": "A normalized Agora certificate operation response."
      }
    },
    {
      "id": "agora.update_project_status",
      "service": "agora",
      "name": "update_project_status",
      "description": "Enable or disable an Agora Console project.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "minLength": 1,
            "description": "An Agora Console project ID."
          },
          "status": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1,
            "description": "The Agora project status, where 1 enables and 0 disables."
          }
        },
        "additionalProperties": false,
        "description": "Input for updating an Agora project status."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "description": "An Agora Console project ID."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora Console project name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "appId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The Agora App ID for the project."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "recordingServer": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The recording server IP address when returned by Agora."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Agora project status, where 1 is enabled and 0 is disabled."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "created": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The Unix timestamp in seconds when the project was created."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "A normalized Agora Console project."
          }
        },
        "additionalProperties": false,
        "description": "The normalized Agora project response."
      }
    }
  ]
}
