{
  "service": "bitly",
  "displayName": "Bitly",
  "categories": [
    "Marketing",
    "Data"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "Generic Access Token",
      "placeholder": "BITLY_ACCESS_TOKEN",
      "description": "Bitly generic access token sent as a Bearer token. Generate it in Bitly Developer settings: https://app.bitly.com/settings/api/."
    }
  ],
  "homepageUrl": "https://bitly.com",
  "actions": [
    {
      "id": "bitly.get_bitlink",
      "service": "bitly",
      "name": "get_bitlink",
      "description": "Get details for an existing Bitly Bitlink.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "bitlink": {
            "type": "string",
            "minLength": 1,
            "description": "A Bitlink made of the domain and hash, such as bit.ly/12a4b6c."
          }
        },
        "additionalProperties": false,
        "required": [
          "bitlink"
        ],
        "description": "Bitly Bitlink lookup input."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "bitlink": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "description": "The Bitlink ID, usually domain/hash."
              },
              "link": {
                "type": "string",
                "description": "The short URL.",
                "format": "uri"
              },
              "long_url": {
                "type": "string",
                "description": "The destination URL.",
                "format": "uri"
              },
              "title": {
                "type": "string",
                "description": "The Bitlink title."
              },
              "archived": {
                "type": "boolean",
                "description": "Whether the Bitlink is archived."
              },
              "created_at": {
                "type": "string",
                "description": "Timestamp when the Bitlink was created."
              },
              "created_by": {
                "type": "string",
                "description": "The login that created the Bitlink."
              },
              "client_id": {
                "type": "string",
                "description": "The client ID that created the Bitlink."
              },
              "custom_bitlinks": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A custom Bitlink."
                },
                "description": "Custom Bitlinks associated with this Bitlink."
              },
              "tags": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "description": "One Bitly tag."
                },
                "description": "Tags assigned to the Bitlink."
              },
              "launchpad_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A Launchpad ID."
                },
                "description": "Launchpad IDs associated with this Bitlink."
              },
              "qr_code_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A QR code ID."
                },
                "description": "QR code IDs associated with this Bitlink."
              },
              "is_deleted": {
                "type": "boolean",
                "description": "Whether the Bitlink has been deleted."
              },
              "campaign_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A campaign ID."
                },
                "description": "Campaign IDs associated with this Bitlink."
              },
              "expiration_at": {
                "type": "string",
                "description": "Optional expiration timestamp for the Bitlink."
              },
              "references": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "description": "A reference URL."
                },
                "description": "Reference URLs returned by Bitly."
              }
            },
            "additionalProperties": true,
            "description": "A Bitly Bitlink."
          }
        },
        "additionalProperties": false,
        "required": [
          "bitlink"
        ],
        "description": "Bitly Bitlink details."
      }
    },
    {
      "id": "bitly.get_group",
      "service": "bitly",
      "name": "get_group",
      "description": "Get details for a Bitly group.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "groupGuid": {
            "type": "string",
            "minLength": 1,
            "description": "A Bitly GUID value."
          }
        },
        "additionalProperties": false,
        "required": [
          "groupGuid"
        ],
        "description": "Bitly group lookup input."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "group": {
            "type": "object",
            "properties": {
              "guid": {
                "type": "string",
                "description": "The group GUID."
              },
              "organization_guid": {
                "type": "string",
                "description": "The organization GUID that owns the group."
              },
              "name": {
                "type": "string",
                "description": "The group name."
              },
              "created": {
                "type": "string",
                "description": "Timestamp when the group was created."
              },
              "modified": {
                "type": "string",
                "description": "Timestamp when the group was last modified."
              },
              "is_active": {
                "type": "boolean",
                "description": "Whether the group is active."
              },
              "role": {
                "type": "string",
                "description": "The authenticated user's role in the group."
              },
              "bsds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A branded domain."
                },
                "description": "Branded short domains associated with the group."
              },
              "references": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "description": "A reference URL."
                },
                "description": "Reference URLs returned by Bitly."
              }
            },
            "additionalProperties": true,
            "description": "A Bitly group."
          }
        },
        "additionalProperties": false,
        "required": [
          "group"
        ],
        "description": "Bitly group details."
      }
    },
    {
      "id": "bitly.get_user",
      "service": "bitly",
      "name": "get_user",
      "description": "Get the authenticated Bitly user details.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "No input is required."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "user": {
            "type": "object",
            "properties": {
              "login": {
                "type": "string",
                "description": "The Bitly login name."
              },
              "name": {
                "type": "string",
                "description": "The user's display name."
              },
              "is_active": {
                "type": "boolean",
                "description": "Whether the user is active."
              },
              "created": {
                "type": "string",
                "description": "Timestamp when the user was created."
              },
              "modified": {
                "type": "string",
                "description": "Timestamp when the user was last modified."
              },
              "is_sso_user": {
                "type": "boolean",
                "description": "Whether the user authenticates through SSO."
              },
              "is_2fa_enabled": {
                "type": "boolean",
                "description": "Whether two-factor authentication is enabled."
              },
              "default_group_guid": {
                "type": "string",
                "description": "The default Bitly group GUID."
              },
              "emails": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "email": {
                      "type": "string",
                      "description": "The email address.",
                      "format": "email"
                    },
                    "is_primary": {
                      "type": "boolean",
                      "description": "Whether this is the primary email address."
                    },
                    "is_verified": {
                      "type": "boolean",
                      "description": "Whether this email address has been verified."
                    }
                  },
                  "additionalProperties": true,
                  "description": "A Bitly user email record."
                },
                "description": "Email addresses associated with the user."
              }
            },
            "additionalProperties": true,
            "description": "Authenticated Bitly user details."
          }
        },
        "additionalProperties": false,
        "required": [
          "user"
        ],
        "description": "Authenticated Bitly user details."
      }
    },
    {
      "id": "bitly.list_groups",
      "service": "bitly",
      "name": "list_groups",
      "description": "List Bitly groups available to the authenticated user.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "organizationGuid": {
            "type": "string",
            "minLength": 1,
            "description": "A Bitly GUID value."
          }
        },
        "additionalProperties": false,
        "description": "Filters for listing Bitly groups."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "guid": {
                  "type": "string",
                  "description": "The group GUID."
                },
                "organization_guid": {
                  "type": "string",
                  "description": "The organization GUID that owns the group."
                },
                "name": {
                  "type": "string",
                  "description": "The group name."
                },
                "created": {
                  "type": "string",
                  "description": "Timestamp when the group was created."
                },
                "modified": {
                  "type": "string",
                  "description": "Timestamp when the group was last modified."
                },
                "is_active": {
                  "type": "boolean",
                  "description": "Whether the group is active."
                },
                "role": {
                  "type": "string",
                  "description": "The authenticated user's role in the group."
                },
                "bsds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "A branded domain."
                  },
                  "description": "Branded short domains associated with the group."
                },
                "references": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "string",
                    "description": "A reference URL."
                  },
                  "description": "Reference URLs returned by Bitly."
                }
              },
              "additionalProperties": true,
              "description": "A Bitly group."
            },
            "description": "Groups returned by Bitly."
          }
        },
        "additionalProperties": false,
        "required": [
          "groups"
        ],
        "description": "Bitly group list."
      }
    },
    {
      "id": "bitly.shorten_link",
      "service": "bitly",
      "name": "shorten_link",
      "description": "Create a short Bitly link for a destination URL.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "longUrl": {
            "type": "string",
            "description": "The destination URL for the Bitlink.",
            "format": "uri"
          },
          "domain": {
            "type": "string",
            "minLength": 1,
            "description": "The domain used when creating the Bitlink."
          },
          "groupGuid": {
            "type": "string",
            "minLength": 1,
            "description": "A Bitly GUID value."
          },
          "forceNewLink": {
            "type": "boolean",
            "description": "Whether Bitly should create a new short link every time."
          }
        },
        "additionalProperties": false,
        "required": [
          "longUrl"
        ],
        "description": "Input for creating a Bitly short link."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "bitlink": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "description": "The Bitlink ID, usually domain/hash."
              },
              "link": {
                "type": "string",
                "description": "The short URL.",
                "format": "uri"
              },
              "long_url": {
                "type": "string",
                "description": "The destination URL.",
                "format": "uri"
              },
              "title": {
                "type": "string",
                "description": "The Bitlink title."
              },
              "archived": {
                "type": "boolean",
                "description": "Whether the Bitlink is archived."
              },
              "created_at": {
                "type": "string",
                "description": "Timestamp when the Bitlink was created."
              },
              "created_by": {
                "type": "string",
                "description": "The login that created the Bitlink."
              },
              "client_id": {
                "type": "string",
                "description": "The client ID that created the Bitlink."
              },
              "custom_bitlinks": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A custom Bitlink."
                },
                "description": "Custom Bitlinks associated with this Bitlink."
              },
              "tags": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "description": "One Bitly tag."
                },
                "description": "Tags assigned to the Bitlink."
              },
              "launchpad_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A Launchpad ID."
                },
                "description": "Launchpad IDs associated with this Bitlink."
              },
              "qr_code_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A QR code ID."
                },
                "description": "QR code IDs associated with this Bitlink."
              },
              "is_deleted": {
                "type": "boolean",
                "description": "Whether the Bitlink has been deleted."
              },
              "campaign_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A campaign ID."
                },
                "description": "Campaign IDs associated with this Bitlink."
              },
              "expiration_at": {
                "type": "string",
                "description": "Optional expiration timestamp for the Bitlink."
              },
              "references": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "description": "A reference URL."
                },
                "description": "Reference URLs returned by Bitly."
              }
            },
            "additionalProperties": true,
            "description": "A Bitly Bitlink."
          }
        },
        "additionalProperties": false,
        "required": [
          "bitlink"
        ],
        "description": "Created Bitly short link."
      }
    },
    {
      "id": "bitly.update_bitlink",
      "service": "bitly",
      "name": "update_bitlink",
      "description": "Update editable fields on an existing Bitly Bitlink.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "bitlink": {
            "type": "string",
            "minLength": 1,
            "description": "A Bitlink made of the domain and hash, such as bit.ly/12a4b6c."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "description": "Updated Bitlink title."
          },
          "archived": {
            "type": "boolean",
            "description": "Whether the Bitlink should be archived."
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "One Bitly tag."
            },
            "description": "Tags assigned to the Bitlink."
          },
          "longUrl": {
            "type": "string",
            "description": "The destination URL for the Bitlink.",
            "format": "uri"
          },
          "expirationAt": {
            "type": "string",
            "minLength": 1,
            "description": "Updated Bitlink expiration timestamp."
          }
        },
        "additionalProperties": false,
        "required": [
          "bitlink"
        ],
        "description": "Input for updating a Bitly Bitlink.",
        "anyOf": [
          {
            "required": [
              "title"
            ]
          },
          {
            "required": [
              "archived"
            ]
          },
          {
            "required": [
              "tags"
            ]
          },
          {
            "required": [
              "longUrl"
            ]
          },
          {
            "required": [
              "expirationAt"
            ]
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "bitlink": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "description": "The Bitlink ID, usually domain/hash."
              },
              "link": {
                "type": "string",
                "description": "The short URL.",
                "format": "uri"
              },
              "long_url": {
                "type": "string",
                "description": "The destination URL.",
                "format": "uri"
              },
              "title": {
                "type": "string",
                "description": "The Bitlink title."
              },
              "archived": {
                "type": "boolean",
                "description": "Whether the Bitlink is archived."
              },
              "created_at": {
                "type": "string",
                "description": "Timestamp when the Bitlink was created."
              },
              "created_by": {
                "type": "string",
                "description": "The login that created the Bitlink."
              },
              "client_id": {
                "type": "string",
                "description": "The client ID that created the Bitlink."
              },
              "custom_bitlinks": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A custom Bitlink."
                },
                "description": "Custom Bitlinks associated with this Bitlink."
              },
              "tags": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "description": "One Bitly tag."
                },
                "description": "Tags assigned to the Bitlink."
              },
              "launchpad_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A Launchpad ID."
                },
                "description": "Launchpad IDs associated with this Bitlink."
              },
              "qr_code_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A QR code ID."
                },
                "description": "QR code IDs associated with this Bitlink."
              },
              "is_deleted": {
                "type": "boolean",
                "description": "Whether the Bitlink has been deleted."
              },
              "campaign_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "A campaign ID."
                },
                "description": "Campaign IDs associated with this Bitlink."
              },
              "expiration_at": {
                "type": "string",
                "description": "Optional expiration timestamp for the Bitlink."
              },
              "references": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "description": "A reference URL."
                },
                "description": "Reference URLs returned by Bitly."
              }
            },
            "additionalProperties": true,
            "description": "A Bitly Bitlink."
          }
        },
        "additionalProperties": false,
        "required": [
          "bitlink"
        ],
        "description": "Updated Bitly Bitlink details."
      }
    }
  ]
}
