{
  "service": "algolia",
  "displayName": "Algolia",
  "categories": [
    "Developer Tools",
    "Data"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "API Key",
      "placeholder": "ALGOLIA_API_KEY",
      "description": "Algolia API Key used with the X-Algolia-API-Key header. Manage keys in the Algolia dashboard: https://dashboard.algolia.com/account/api-keys.",
      "extraFields": [
        {
          "key": "applicationId",
          "label": "Application ID",
          "inputType": "text",
          "required": true,
          "secret": false,
          "placeholder": "Your Algolia Application ID",
          "description": "The Algolia application ID paired with the API key for Search API requests. Find it in the Algolia dashboard or see https://support.algolia.com/hc/en-us/articles/11040113398673-Where-can-I-find-my-application-ID-and-the-index-name."
        }
      ]
    }
  ],
  "homepageUrl": "https://www.algolia.com",
  "actions": [
    {
      "id": "algolia.add_or_replace_record",
      "service": "algolia",
      "name": "add_or_replace_record",
      "description": "Add a new record or replace an existing Algolia record using its objectID.",
      "requiredScopes": [
        "addObject"
      ],
      "providerPermissions": [
        "addObject"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "record": {
            "type": "object",
            "properties": {
              "objectID": {
                "type": "string",
                "minLength": 1,
                "description": "The Algolia record objectID."
              }
            },
            "additionalProperties": true,
            "description": "The Algolia record payload."
          },
          "forwardToReplicas": {
            "type": "boolean",
            "description": "Whether to forward the write operation to replicas."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName",
          "record"
        ],
        "description": "The input payload for adding or replacing an Algolia record."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "taskID": {
            "type": "number",
            "description": "The Algolia task identifier."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "The task acknowledgement returned by Algolia."
      }
    },
    {
      "id": "algolia.browse_index",
      "service": "algolia",
      "name": "browse_index",
      "description": "Browse records from a single Algolia index, optionally continuing with a cursor.",
      "requiredScopes": [
        "browse"
      ],
      "providerPermissions": [
        "browse"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "cursor": {
            "type": "string",
            "description": "The cursor returned by the previous browse response."
          },
          "query": {
            "type": "string",
            "description": "An optional browse query string."
          },
          "filters": {
            "type": "string",
            "minLength": 1,
            "description": "The filter expression using Algolia's SQL-like syntax."
          },
          "facetFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "numericFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "tagFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "attributesToRetrieve": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          },
          "hitsPerPage": {
            "type": "integer",
            "minimum": 1,
            "description": "The number of hits to return per page."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName"
        ],
        "description": "The input payload for browsing an Algolia index."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "hits": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "objectID": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Algolia record objectID."
                }
              },
              "additionalProperties": true,
              "description": "An Algolia record or search hit."
            },
            "description": "The records returned by the browse request."
          },
          "cursor": {
            "type": "string",
            "description": "The cursor to continue browsing from the next page."
          },
          "nbHits": {
            "type": "number",
            "description": "The total number of matching records, when available."
          },
          "processingTimeMS": {
            "type": "number",
            "description": "The time the server took to process the request, in milliseconds."
          }
        },
        "additionalProperties": true,
        "description": "An Algolia browse response."
      }
    },
    {
      "id": "algolia.delete_records_by_filter",
      "service": "algolia",
      "name": "delete_records_by_filter",
      "description": "Delete Algolia records that match a filter expression.",
      "requiredScopes": [
        "deleteIndex"
      ],
      "providerPermissions": [
        "deleteIndex"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "filters": {
            "type": "string",
            "minLength": 1,
            "description": "The filter expression used to select records to delete."
          }
        },
        "additionalProperties": false,
        "description": "The input payload for deleting Algolia records by filter."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "taskID": {
            "type": "number",
            "description": "The Algolia task identifier."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "The task acknowledgement returned by Algolia."
      }
    },
    {
      "id": "algolia.get_record",
      "service": "algolia",
      "name": "get_record",
      "description": "Retrieve a single record from an Algolia index by objectID.",
      "requiredScopes": [
        "search"
      ],
      "providerPermissions": [
        "search"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          },
          "attributesToRetrieve": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName",
          "objectID"
        ],
        "description": "The input payload for retrieving a single Algolia record."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "An Algolia record or search hit."
      }
    },
    {
      "id": "algolia.list_indices",
      "service": "algolia",
      "name": "list_indices",
      "description": "List Algolia indices accessible to the current API key.",
      "requiredScopes": [
        "listIndexes"
      ],
      "providerPermissions": [
        "listIndexes"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "page": {
            "type": "integer",
            "minimum": 0,
            "description": "The zero-based page number."
          },
          "hitsPerPage": {
            "type": "integer",
            "minimum": 1,
            "description": "The number of hits to return per page."
          }
        },
        "additionalProperties": false,
        "description": "The input payload for listing Algolia indices."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string",
                  "description": "The Algolia index name."
                },
                "entries": {
                  "type": "number",
                  "description": "The number of records in the index."
                },
                "dataSize": {
                  "type": "number",
                  "description": "The size of the index data in bytes."
                },
                "fileSize": {
                  "type": "number",
                  "description": "The total size of the index files in bytes."
                },
                "numberOfPendingTasks": {
                  "type": "number",
                  "description": "The number of pending tasks for the index."
                },
                "primary": {
                  "type": "string",
                  "description": "The primary index name, when this index is a replica."
                },
                "replicas": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "A replica index name."
                  },
                  "description": "The configured replica index names."
                },
                "pendingTask": {
                  "type": "boolean",
                  "description": "Whether the index has a pending task."
                }
              },
              "additionalProperties": true,
              "description": "A summary of an Algolia index."
            },
            "description": "The list of index summaries."
          },
          "page": {
            "type": "number",
            "description": "The zero-based page number in the response."
          },
          "nbPages": {
            "type": "number",
            "description": "The total number of pages."
          }
        },
        "additionalProperties": true,
        "description": "The response returned when listing Algolia indices."
      }
    },
    {
      "id": "algolia.save_rule",
      "service": "algolia",
      "name": "save_rule",
      "description": "Save a single Algolia rule by objectID.",
      "requiredScopes": [
        "settings"
      ],
      "providerPermissions": [
        "settings"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "rule": {
            "type": "object",
            "properties": {
              "objectID": {
                "type": "string",
                "minLength": 1,
                "description": "The Algolia record objectID."
              }
            },
            "additionalProperties": true,
            "description": "The Algolia rule payload."
          },
          "forwardToReplicas": {
            "type": "boolean",
            "description": "Whether to forward the write operation to replicas."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName",
          "rule"
        ],
        "description": "The input payload for saving a single Algolia rule."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "taskID": {
            "type": "number",
            "description": "The Algolia task identifier."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "The task acknowledgement returned by Algolia."
      }
    },
    {
      "id": "algolia.save_synonym",
      "service": "algolia",
      "name": "save_synonym",
      "description": "Save a single Algolia synonym by objectID.",
      "requiredScopes": [
        "settings"
      ],
      "providerPermissions": [
        "settings"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "synonym": {
            "type": "object",
            "properties": {
              "objectID": {
                "type": "string",
                "minLength": 1,
                "description": "The Algolia record objectID."
              }
            },
            "additionalProperties": true,
            "description": "The Algolia synonym payload."
          },
          "forwardToReplicas": {
            "type": "boolean",
            "description": "Whether to forward the write operation to replicas."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName",
          "synonym"
        ],
        "description": "The input payload for saving a single Algolia synonym."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "taskID": {
            "type": "number",
            "description": "The Algolia task identifier."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "The task acknowledgement returned by Algolia."
      }
    },
    {
      "id": "algolia.search_index",
      "service": "algolia",
      "name": "search_index",
      "description": "Search a single Algolia index with the most common search parameters.",
      "requiredScopes": [
        "search"
      ],
      "providerPermissions": [
        "search"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "query": {
            "type": "string",
            "description": "The search query string."
          },
          "page": {
            "type": "integer",
            "minimum": 0,
            "description": "The zero-based page number."
          },
          "hitsPerPage": {
            "type": "integer",
            "minimum": 1,
            "description": "The number of hits to return per page."
          },
          "filters": {
            "type": "string",
            "minLength": 1,
            "description": "The filter expression using Algolia's SQL-like syntax."
          },
          "facetFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "numericFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "tagFilters": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "A single filter value."
              },
              {
                "type": "array",
                "items": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "description": "A single filter value."
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "description": "A single filter value."
                      },
                      "description": "A group of OR filter values.",
                      "minItems": 1
                    }
                  ]
                },
                "description": "An Algolia filter array or grouped filter arrays.",
                "minItems": 1
              }
            ],
            "description": "An Algolia filter expression in string or array form."
          },
          "facets": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          },
          "attributesToRetrieve": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          },
          "attributesToHighlight": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          },
          "attributesToSnippet": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A non-empty string value."
            },
            "description": "A list of non-empty strings.",
            "minItems": 1
          },
          "aroundLatLng": {
            "type": "string",
            "description": "The geolocation point in `lat,lng` form."
          },
          "aroundRadius": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "description": "The radius in meters."
              },
              {
                "const": "all",
                "type": "string",
                "description": "Disable the around radius limit."
              }
            ],
            "description": "The geolocation radius restriction."
          },
          "insideBoundingBox": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "The bounding box encoded as a string."
              },
              {
                "type": "array",
                "items": {
                  "type": "number",
                  "description": "A latitude or longitude coordinate."
                },
                "description": "A flat list of bounding box coordinates.",
                "minItems": 4
              },
              {
                "type": "array",
                "items": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "description": "A latitude or longitude coordinate."
                  },
                  "description": "A single bounding box coordinate list.",
                  "minItems": 4
                },
                "description": "A list of bounding box coordinate lists.",
                "minItems": 1
              }
            ],
            "description": "Bounding box coordinates used to restrict the search area."
          },
          "insidePolygon": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "The polygon encoded as a string."
              },
              {
                "type": "array",
                "items": {
                  "type": "number",
                  "description": "A latitude or longitude coordinate."
                },
                "description": "A flat list of polygon coordinates.",
                "minItems": 6
              },
              {
                "type": "array",
                "items": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "description": "A latitude or longitude coordinate."
                  },
                  "description": "A single polygon coordinate list.",
                  "minItems": 6
                },
                "description": "A list of polygon coordinate lists.",
                "minItems": 1
              }
            ],
            "description": "Polygon coordinates used to restrict the search area."
          },
          "clickAnalytics": {
            "type": "boolean",
            "description": "Whether to include click analytics information."
          },
          "analytics": {
            "type": "boolean",
            "description": "Whether to send the search to Algolia analytics."
          },
          "getRankingInfo": {
            "type": "boolean",
            "description": "Whether to include ranking information in the response."
          },
          "sumOrFiltersScores": {
            "type": "boolean",
            "description": "Whether to sum OR filter scores instead of taking the maximum."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName"
        ],
        "description": "The input payload for searching a single Algolia index."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "hits": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "objectID": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The Algolia record objectID."
                }
              },
              "additionalProperties": true,
              "description": "An Algolia record or search hit."
            },
            "description": "The search hits returned by Algolia."
          },
          "nbHits": {
            "type": "number",
            "description": "The total number of matching hits."
          },
          "page": {
            "type": "number",
            "description": "The zero-based page number in the response."
          },
          "nbPages": {
            "type": "number",
            "description": "The total number of pages."
          },
          "hitsPerPage": {
            "type": "number",
            "description": "The number of hits returned per page."
          },
          "processingTimeMS": {
            "type": "number",
            "description": "The time the server took to process the request, in milliseconds."
          },
          "exhaustiveNbHits": {
            "type": "boolean",
            "description": "Whether the reported hit count is exhaustive."
          },
          "query": {
            "type": "string",
            "description": "The query used for the search."
          },
          "params": {
            "type": "string",
            "description": "The URL-encoded request parameters."
          },
          "facets": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Facet counts returned by Algolia."
          },
          "facetStats": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Facet statistics returned by Algolia."
          }
        },
        "additionalProperties": true,
        "description": "An Algolia search response."
      }
    },
    {
      "id": "algolia.update_record_partially",
      "service": "algolia",
      "name": "update_record_partially",
      "description": "Partially update an existing Algolia record by objectID.",
      "requiredScopes": [
        "addObject"
      ],
      "providerPermissions": [
        "addObject"
      ],
      "inputSchema": {
        "type": "object",
        "properties": {
          "indexName": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia index name."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          },
          "attributesToUpdate": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The partial Algolia record attributes to update."
          },
          "createIfNotExists": {
            "type": "boolean",
            "description": "Whether to create the record if it doesn't exist."
          },
          "forwardToReplicas": {
            "type": "boolean",
            "description": "Whether to forward the write operation to replicas."
          }
        },
        "additionalProperties": false,
        "required": [
          "indexName",
          "objectID",
          "attributesToUpdate"
        ],
        "description": "The input payload for partially updating an Algolia record."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "taskID": {
            "type": "number",
            "description": "The Algolia task identifier."
          },
          "objectID": {
            "type": "string",
            "minLength": 1,
            "description": "The Algolia record objectID."
          }
        },
        "additionalProperties": true,
        "description": "The task acknowledgement returned by Algolia."
      }
    }
  ]
}
