/*
* Linkbreakers API
*
* This is a documentation of all the APIs of Linkbreakers ## Entry points `GET https://api.linkbreakers.com/` and `GET https://api.linkbreakers.com/v1` answer without credentials with the API's name, version and links. This document is served at `https://api.linkbreakers.com/openapi.json`. ## Rate limits Every response describes where the caller stands in the IETF `RateLimit-Policy` and `RateLimit` header fields (draft-ietf-httpapi-ratelimit-headers), and in `RateLimit-Limit`, `RateLimit-Remaining`, `RateLimit-Reset` and `X-RateLimit-Limit`, `X-RateLimit-Remaining`, `X-RateLimit-Reset` (a Unix timestamp) for clients that read those. A request past the limit gets `429 Too Many Requests` with `Retry-After` in seconds. - Workspace API token: 600 requests per 60 seconds, per token. - Dashboard session or OAuth token: 500 requests per 60 seconds, per token. - No credentials: 300 requests per 60 seconds, per client IP. Each plan also includes a number of API calls per billing cycle. Past it, calls answer `429` with the code `MAX_PUBLIC_API_QUERIED_REACHED` until the cycle renews or the plan changes. ## Pagination Every list pages with opaque cursors (AIP-158). Pass `pageSize`, then send the `nextPageToken` of each response back as `pageToken` (or its alias `cursor`) to get the next page. An empty or absent `nextPageToken` means the list is complete. Each list operation describes this in `x-pagination`. ## Batches and background jobs `POST /v1/links/bulk` creates up to 250 links in one transactional request; `POST /v1/links/batch` takes the same links as a bare JSON array. `POST /v1/links/bulk/jobs` accepts the same batch and answers `202 Accepted` at once with a job and a `Location` header; poll `GET /v1/jobs/{id}` until `status` is `JOB_STATUS_SUCCEEDED` (the created link ids are in `linksBulkCreate.linkIds`) or `JOB_STATUS_FAILED` (`error` says why, and nothing was created). Jobs can be read for 24 hours after they finish. ## Versioning and deprecation The version is in the path: every operation lives under `/v1`. Within a version, changes are additive only: new operations, new optional request fields, new response fields and new enum values. Clients should ignore fields and enum values they do not know. Anything that would break an existing client ships under a new path version instead. An operation is retired in two steps. First it is deprecated: it keeps working, is flagged `deprecated: true` in this document, and every response carries a `Deprecation` header field (RFC 9745) with the time it was deprecated and a `Link` with `rel=\"deprecation\"` to the policy. Then, at least 180 days later, it may be removed; that date is announced in advance in a `Sunset` header field (RFC 8594) and as `x-sunset` on the operation. The full policy: https://linkbreakers.com/help/article/api-versioning-and-deprecation-policy ## Idempotent retries Every POST, PUT and PATCH accepts an optional `Idempotency-Key` header (draft-ietf-httpapi-idempotency-key-header). Send a new unique value, such as a UUID, with each logical request and reuse it only to retry that request. A retry with the same key and the same request returns the first response, marked `Idempotent-Replayed: true`, instead of running again. Keys are scoped to the token and kept for 24 hours. The same key with a different request is refused with `422`, and a retry while the first request is still running gets `409` with `Retry-After`. Server errors (5xx) and refusals such as 401, 403 and 429 are not stored, so retrying them runs the request again.
*
* The version of the OpenAPI document: 1.180.0
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// EventAction : - EVENT_ACTION_UNSPECIFIED: Event action not specified - EVENT_ACTION_CLIENT_REDIRECT: Redirect visitors to a destination URL - EVENT_ACTION_LINK_VISIT: Entry step triggered when the link is visited. - EVENT_ACTION_PASSWORD_VERIFY: Require visitors to enter a password before proceeding - EVENT_ACTION_FORM_SUBMIT: Present a data collection form to visitors - EVENT_ACTION_CONTACT_CARD: Generate a vCard (VCF) response with contact information - EVENT_ACTION_MULTI_LINK: A page of buttons where each one continues into more workflow: the button leads to a next step, not straight out. Records which button the visitor pressed, so use it over SOCIAL_LINKS_PAGE when that choice is worth measuring or when a branch needs to do more than redirect. This is the menu step: for several documents or PDFs, give each one a button connected to an OPEN_MEDIA step for media uploaded to the media library, or to a CLIENT_REDIRECT when the document is already hosted at a URL. - EVENT_ACTION_VISIT_TYPE_CONDITION: Route visitors based on whether it's a first or returning visit - EVENT_ACTION_COUNTRY_CONDITION: Route visitors based on their country location - EVENT_ACTION_DAY_OF_WEEK_CONDITION: Route visitors based on day of week - EVENT_ACTION_TIME_OF_DAY_CONDITION: Route visitors based on time of day - EVENT_ACTION_DAY_OF_MONTH_CONDITION: Route visitors based on day of month - EVENT_ACTION_SPECIFIC_DATE_CONDITION: Route visitors based on specific calendar dates - EVENT_ACTION_SOCIAL_LINKS_PAGE: A page of buttons that each leave for an external URL. Social profiles are the common case, not the only one: app stores, docs, booking pages and storefronts all work, and the name is the only thing about it that is social. It is an exit step, so the visitor leaves from here. - EVENT_ACTION_DEVICE_TYPE_CONDITION: Route visitors based on device type (e.g. MOBILE, DESKTOP, TABLET) - EVENT_ACTION_DEVICE_PLATFORM_CONDITION: Route visitors based on device platform / operating system (e.g. iOS, Android, macOS) - EVENT_ACTION_DEVICE_BROWSER_CONDITION: Route visitors based on browser family (e.g. Chrome, Safari, Firefox) - EVENT_ACTION_DEVICE_BRAND_CONDITION: Route visitors based on hardware brand (e.g. Apple, Samsung, Google) - EVENT_ACTION_DEVICE_ACTOR_CONDITION: Route visitors based on actor classification (e.g. HUMAN, BOT, AGENT) - EVENT_ACTION_VISITOR_DATA_CONDITION: Route visitors based on their profile data or custom attributes - EVENT_ACTION_THANK_YOU_PAGE: Display a final thank you / completion message (exit step) - EVENT_ACTION_MESSAGE_PAGE: Text with ONE way onward: a single button, or a timer that moves the visitor automatically. It carries no list of destinations, so a page that should offer a choice between two or more places is not this step. Use SOCIAL_LINKS_PAGE when the choices leave for external URLs, or MULTI_LINK when each choice continues into more workflow. Never put links, documents or PDFs on it: it is a message, nothing else. - EVENT_ACTION_OPEN_MEDIA: Hand the visitor one piece of uploaded media, opened in their browser (exit step): a PDF, an image (PNG, JPEG, WebP, SVG) or an MP4 video. The visitor is sent straight to the media, with no page of its own. Any media of the library can be opened: it is uploaded once and referenced by its media_id; swapping it means pointing the step at another media item, and the QR code never changes.
/// - EVENT_ACTION_UNSPECIFIED: Event action not specified - EVENT_ACTION_CLIENT_REDIRECT: Redirect visitors to a destination URL - EVENT_ACTION_LINK_VISIT: Entry step triggered when the link is visited. - EVENT_ACTION_PASSWORD_VERIFY: Require visitors to enter a password before proceeding - EVENT_ACTION_FORM_SUBMIT: Present a data collection form to visitors - EVENT_ACTION_CONTACT_CARD: Generate a vCard (VCF) response with contact information - EVENT_ACTION_MULTI_LINK: A page of buttons where each one continues into more workflow: the button leads to a next step, not straight out. Records which button the visitor pressed, so use it over SOCIAL_LINKS_PAGE when that choice is worth measuring or when a branch needs to do more than redirect. This is the menu step: for several documents or PDFs, give each one a button connected to an OPEN_MEDIA step for media uploaded to the media library, or to a CLIENT_REDIRECT when the document is already hosted at a URL. - EVENT_ACTION_VISIT_TYPE_CONDITION: Route visitors based on whether it's a first or returning visit - EVENT_ACTION_COUNTRY_CONDITION: Route visitors based on their country location - EVENT_ACTION_DAY_OF_WEEK_CONDITION: Route visitors based on day of week - EVENT_ACTION_TIME_OF_DAY_CONDITION: Route visitors based on time of day - EVENT_ACTION_DAY_OF_MONTH_CONDITION: Route visitors based on day of month - EVENT_ACTION_SPECIFIC_DATE_CONDITION: Route visitors based on specific calendar dates - EVENT_ACTION_SOCIAL_LINKS_PAGE: A page of buttons that each leave for an external URL. Social profiles are the common case, not the only one: app stores, docs, booking pages and storefronts all work, and the name is the only thing about it that is social. It is an exit step, so the visitor leaves from here. - EVENT_ACTION_DEVICE_TYPE_CONDITION: Route visitors based on device type (e.g. MOBILE, DESKTOP, TABLET) - EVENT_ACTION_DEVICE_PLATFORM_CONDITION: Route visitors based on device platform / operating system (e.g. iOS, Android, macOS) - EVENT_ACTION_DEVICE_BROWSER_CONDITION: Route visitors based on browser family (e.g. Chrome, Safari, Firefox) - EVENT_ACTION_DEVICE_BRAND_CONDITION: Route visitors based on hardware brand (e.g. Apple, Samsung, Google) - EVENT_ACTION_DEVICE_ACTOR_CONDITION: Route visitors based on actor classification (e.g. HUMAN, BOT, AGENT) - EVENT_ACTION_VISITOR_DATA_CONDITION: Route visitors based on their profile data or custom attributes - EVENT_ACTION_THANK_YOU_PAGE: Display a final thank you / completion message (exit step) - EVENT_ACTION_MESSAGE_PAGE: Text with ONE way onward: a single button, or a timer that moves the visitor automatically. It carries no list of destinations, so a page that should offer a choice between two or more places is not this step. Use SOCIAL_LINKS_PAGE when the choices leave for external URLs, or MULTI_LINK when each choice continues into more workflow. Never put links, documents or PDFs on it: it is a message, nothing else. - EVENT_ACTION_OPEN_MEDIA: Hand the visitor one piece of uploaded media, opened in their browser (exit step): a PDF, an image (PNG, JPEG, WebP, SVG) or an MP4 video. The visitor is sent straight to the media, with no page of its own. Any media of the library can be opened: it is uploaded once and referenced by its media_id; swapping it means pointing the step at another media item, and the QR code never changes.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum EventAction {
#[serde(rename = "EVENT_ACTION_UNSPECIFIED")]
EventActionUnspecified,
#[serde(rename = "EVENT_ACTION_CLIENT_REDIRECT")]
EventActionClientRedirect,
#[serde(rename = "EVENT_ACTION_LINK_VISIT")]
EventActionLinkVisit,
#[serde(rename = "EVENT_ACTION_PASSWORD_VERIFY")]
EventActionPasswordVerify,
#[serde(rename = "EVENT_ACTION_FORM_SUBMIT")]
EventActionFormSubmit,
#[serde(rename = "EVENT_ACTION_CONTACT_CARD")]
EventActionContactCard,
#[serde(rename = "EVENT_ACTION_MULTI_LINK")]
EventActionMultiLink,
#[serde(rename = "EVENT_ACTION_VISIT_TYPE_CONDITION")]
EventActionVisitTypeCondition,
#[serde(rename = "EVENT_ACTION_COUNTRY_CONDITION")]
EventActionCountryCondition,
#[serde(rename = "EVENT_ACTION_DAY_OF_WEEK_CONDITION")]
EventActionDayOfWeekCondition,
#[serde(rename = "EVENT_ACTION_TIME_OF_DAY_CONDITION")]
EventActionTimeOfDayCondition,
#[serde(rename = "EVENT_ACTION_DAY_OF_MONTH_CONDITION")]
EventActionDayOfMonthCondition,
#[serde(rename = "EVENT_ACTION_SPECIFIC_DATE_CONDITION")]
EventActionSpecificDateCondition,
#[serde(rename = "EVENT_ACTION_SOCIAL_LINKS_PAGE")]
EventActionSocialLinksPage,
#[serde(rename = "EVENT_ACTION_DEVICE_TYPE_CONDITION")]
EventActionDeviceTypeCondition,
#[serde(rename = "EVENT_ACTION_DEVICE_PLATFORM_CONDITION")]
EventActionDevicePlatformCondition,
#[serde(rename = "EVENT_ACTION_DEVICE_BROWSER_CONDITION")]
EventActionDeviceBrowserCondition,
#[serde(rename = "EVENT_ACTION_DEVICE_BRAND_CONDITION")]
EventActionDeviceBrandCondition,
#[serde(rename = "EVENT_ACTION_DEVICE_ACTOR_CONDITION")]
EventActionDeviceActorCondition,
#[serde(rename = "EVENT_ACTION_VISITOR_DATA_CONDITION")]
EventActionVisitorDataCondition,
#[serde(rename = "EVENT_ACTION_THANK_YOU_PAGE")]
EventActionThankYouPage,
#[serde(rename = "EVENT_ACTION_MESSAGE_PAGE")]
EventActionMessagePage,
#[serde(rename = "EVENT_ACTION_OPEN_MEDIA")]
EventActionOpenMedia,
}
impl std::fmt::Display for EventAction {
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
match self {
Self::EventActionUnspecified => write!(f, "EVENT_ACTION_UNSPECIFIED"),
Self::EventActionClientRedirect => write!(f, "EVENT_ACTION_CLIENT_REDIRECT"),
Self::EventActionLinkVisit => write!(f, "EVENT_ACTION_LINK_VISIT"),
Self::EventActionPasswordVerify => write!(f, "EVENT_ACTION_PASSWORD_VERIFY"),
Self::EventActionFormSubmit => write!(f, "EVENT_ACTION_FORM_SUBMIT"),
Self::EventActionContactCard => write!(f, "EVENT_ACTION_CONTACT_CARD"),
Self::EventActionMultiLink => write!(f, "EVENT_ACTION_MULTI_LINK"),
Self::EventActionVisitTypeCondition => write!(f, "EVENT_ACTION_VISIT_TYPE_CONDITION"),
Self::EventActionCountryCondition => write!(f, "EVENT_ACTION_COUNTRY_CONDITION"),
Self::EventActionDayOfWeekCondition => write!(f, "EVENT_ACTION_DAY_OF_WEEK_CONDITION"),
Self::EventActionTimeOfDayCondition => write!(f, "EVENT_ACTION_TIME_OF_DAY_CONDITION"),
Self::EventActionDayOfMonthCondition => write!(f, "EVENT_ACTION_DAY_OF_MONTH_CONDITION"),
Self::EventActionSpecificDateCondition => write!(f, "EVENT_ACTION_SPECIFIC_DATE_CONDITION"),
Self::EventActionSocialLinksPage => write!(f, "EVENT_ACTION_SOCIAL_LINKS_PAGE"),
Self::EventActionDeviceTypeCondition => write!(f, "EVENT_ACTION_DEVICE_TYPE_CONDITION"),
Self::EventActionDevicePlatformCondition => write!(f, "EVENT_ACTION_DEVICE_PLATFORM_CONDITION"),
Self::EventActionDeviceBrowserCondition => write!(f, "EVENT_ACTION_DEVICE_BROWSER_CONDITION"),
Self::EventActionDeviceBrandCondition => write!(f, "EVENT_ACTION_DEVICE_BRAND_CONDITION"),
Self::EventActionDeviceActorCondition => write!(f, "EVENT_ACTION_DEVICE_ACTOR_CONDITION"),
Self::EventActionVisitorDataCondition => write!(f, "EVENT_ACTION_VISITOR_DATA_CONDITION"),
Self::EventActionThankYouPage => write!(f, "EVENT_ACTION_THANK_YOU_PAGE"),
Self::EventActionMessagePage => write!(f, "EVENT_ACTION_MESSAGE_PAGE"),
Self::EventActionOpenMedia => write!(f, "EVENT_ACTION_OPEN_MEDIA"),
}
}
}
impl Default for EventAction {
fn default() -> EventAction {
Self::EventActionUnspecified
}
}