Skip to main content

Queries

  • attributionSettings (Experimental) — How this store attributes orders to its marketing messages: the default attribution model and which evidence counts, with its window. Reading never changes anything.
  • backInStockSubscriptions — List back-in-stock subscriptions for this store, oldest first.
  • campaign — Fetch a single campaign by its id. Ids from earlier versions of the Redo API are also accepted.
  • campaigns — List campaigns, optionally filtered by name, channel, status, tag, or when they finished sending. For sends, opens, clicks and revenue, select analytics { messaging(startDate:, endDate:) } on each node, and analytics { variants(startDate:, endDate:) } for each split-test arm; one range is read once for the whole page.
  • campaignSendCheck — Check a campaign before sending or scheduling it, without changing it: what blocks the send, how many customers it reaches, whether that is a large send for email, and whether the time is in SMS quiet hours. It applies the rules the Redo app applies, and campaignSend refuses the blockers. It runs one audience estimate, cached for 5 minutes, which can take a while for a large dynamic segment. The quiet-hours check uses at, else localTime, else the campaign’s saved schedule, else now. Returns null if no campaign with that id is owned by the caller.
  • commerceAgentStrategies — Commerce Agent strategies on this store, newest first, optionally filtered by name. At most 100 are returned; narrow with query to reach older ones.
  • commerceAgentStrategy — Look up a Commerce Agent strategy by id. Returns null when this store has no strategy with that id.
  • customerCustomFieldDeclaration — Fetch a single customer custom field declaration by its id. Ids from earlier versions of the Redo API are also accepted.
  • customerCustomFieldDeclarations — List customer custom field declarations in this store’s catalog, optionally filtered by name or data type.
  • customerTag — Fetch a single customer tag by its id. Ids from earlier versions of the Redo API are also accepted.
  • customerTags — List customer tags in this store’s catalog, optionally filtered by name, provider, or source.
  • discountCode — Fetch a single discount configuration by its id. Ids from earlier versions of the Redo API are also accepted.
  • discountCodes — List discount configurations, optionally filtered by title or code text, exact checkout code, platform, group type, or kind.
  • emailAddresses — Mailboxes the store can use as a campaign From or Reply-To address.
  • emailDomain — Get one of the store’s email domains by id. Returns null if no domain of the store matches.
  • emailDomains — Domains the store sends email from, with the DNS records each one needs.
  • emailTemplate — Fetch a single email template by its id. Ids from earlier versions of the Redo API are also accepted.
  • emailTemplates — List email templates, optionally filtered by name or trigger.
  • emailTemplateVariableCatalog — The static email-template variable grammar for a trigger: template variable names, Url keys, context objects, and table collection paths. Does not include this store’s discounts, saved sections, or product filters. UNKNOWN returns empty lists.
  • generatedDiscountCodes (Experimental) — List the unique codes generated from one discount configuration, newest first, as the discount page shows them. The list is search-indexed and can trail a new code by a few seconds. An unknown discount returns no codes.
  • marketingAutomation — Fetch a single marketing automation by its id. Ids from earlier versions of the Redo API are also accepted. Also returns a Redo default automation this store sees (origin: DEFAULT).
  • marketingAutomationCatalog — This store’s automation grammar: trigger keys createMarketingAutomation accepts, which step kinds an insert operation accepts for each trigger, and the fields, predicate JSON Schema, and triggerSpecificFields JSON Schema for each trigger. Read it before creating an automation, inserting a step, or writing a condition.
  • marketingAutomations — List marketing automations, optionally filtered by name, category, channel, or whether they are running. For sends, opens, clicks and revenue, select analytics { messaging(startDate:, endDate:) } on each node; one range is read once for the whole page.
  • marketingEmailSettings — The store’s default From and Reply-To addresses for marketing emails.
  • messageDecisions (Experimental) — Why Redo did or didn’t message shoppers: each decision to send, skip, wait or branch, newest first. Filters combine with AND.
  • orderLookup — Fetch the store’s Shopify order-lookup embed. Returns null until one has been created.
  • popup (Experimental) — Fetch a single popup by its id. Ids from earlier versions of the Redo API are also accepted.
  • popups (Experimental) — List this store’s popups, optionally filtered by status.
  • productFilter — Fetch one product filter saved on this account. An id from another account, or one that does not exist, is null.
  • productFilterCollection — One collection on this account’s connected store. An id that store does not have is null. Uses the account’s saved integration only.
  • productFilterCollections — Collections on this account’s connected store for the given provider. Uses that account’s saved integration only — there is no shop domain or token argument. A provider this account has not connected returns an empty list. At most 100 collections are returned.
  • productFilterMetafields — Product metafield definitions from this account’s Shopify Admin API, using the account’s saved Shopify connection. Accounts without Shopify get an empty list. Definitions are capped at 100. Provider errors do not include the Shopify response.
  • productFilters — Product filters saved on this account.
  • segment — Fetch a single segment by its id. Ids from earlier versions of the Redo API are also accepted.
  • segmentConditionCatalog — The static segment condition grammar: fields, operators, and the JSON Schema for conditions. Does not include this store’s tags, products, or customers.
  • segments — List segments, optionally filtered by name or by how membership is set.
  • segmentTokenFieldOptions — Look up this store’s allowed values for a catalog field (tags, products, countries, custom fields, event names). The catalog is static; these values are not.
  • smsKeyword (Experimental) — Fetch one SMS subscribe keyword by its id. Returns null if no keyword in this store has the id.
  • smsKeywords (Experimental) — List the store’s SMS subscribe keywords, optionally only active or only paused ones.
  • smsTemplate — Fetch a single SMS template by its id. Ids from earlier versions of the Redo API are also accepted.
  • smsTemplates — List SMS templates, optionally filtered by name or trigger.
  • trackingPage — Fetch a single tracking page by its id or legacyId. Returns null if no owned tracking page matches.
  • trackingPageBlockSchema (Experimental) — JSON Schema for TrackingPage.blocks.
  • trackingPages — List the store’s tracking pages.

Mutations

  • attributionSettingsReset (Experimental) — Put every attribution setting back to its default: last touch as the default model, and each kind of evidence switched on or off with its window as a new store has it. Returns the settings after the reset.
  • attributionSettingsUpdate (Experimental) — Change how this store attributes orders to its marketing messages, the same settings the Redo app’s attribution page saves. Only the fields you pass change. Returns the settings after the change. BAD_USER_INPUT (400) for a null, a window of zero or past 30 days, a window on CODE_REDEEMED or MEANINGFUL_CONVERSATION, or a kind of evidence listed twice; nothing is saved then.
  • campaignSend — Send a campaign now, as Send now in the Redo app does: it schedules the campaign for the current time and starts the send at once. It works on a draft and on a campaign scheduled for later whose send has not started; the new time replaces the old schedule, and scheduledAtTimeZone is left as it was. Nothing is saved when the send is refused. It fails with CAMPAIGN_NOT_SENDABLE (400) when the campaign has no segment, an email variant lacks a subject or preview text, or marketing billing is off for its channel (campaignSendCheck lists them), and with CAMPAIGN_SEND_STARTED (400) when the send has already started. There is no idempotency key because the campaign is the key: repeating the call after the send started fails with CAMPAIGN_SEND_STARTED, so read the campaign’s status to see the outcome. An SMS campaign sent outside texting hours, 8:00 to 20:00 in part of the continental US, fails with SMS_QUIET_HOURS (400) unless sendDuringQuietHours is true; that acknowledges the risk of texting outside those hours, because Redo does not hold a campaign’s texts for quiet hours once its send starts. updateCampaign is unchanged: it schedules and edits without these checks. Returns null if no campaign with that id is owned by the caller.
  • cancelCampaign — Stop an in-progress campaign. Returns null if no campaign with that id is owned by the caller.
  • commerceAgentStrategyPublish (Experimental) — Publish a Commerce Agent strategy’s staged draft, so agents use its guidance. Fails with COMMERCE_AGENT_STRATEGY_REVISION_STALE when the draft changed since expectedRevision, including when another draft was published since. Repeating a publish that already went live returns the strategy unchanged. Returns null when this store has no strategy with that id.
  • createCampaign — Create a campaign shell. Email requires subject and previewText. Set the audience and schedule with updateCampaign.
  • createCommerceAgentStrategy — Create a Commerce Agent strategy. Set its id as strategyId when inserting a Start Agent Conversation step.
  • createCustomerTag — Create a customer tag in this store’s Redo catalog. The tag’s source is Redo Marketing.
  • createDiscountCode — Create a discount code on Shopify or BigCommerce. The same input is used for both providers.
  • createDynamicSegment — Create a dynamic segment from a condition tree. Attach it to a campaign with updateCampaign.segmentIds.
  • createEmailTemplate — Create an email template. trigger is required and cannot be UNKNOWN. Optional operations are applied to the default sections.
  • createMarketingAutomation — Create an automation for a trigger listed in marketingAutomationCatalog. Returns the new automation. Date and price-drop triggers are not supported.
  • createMarketingImageUpload — Start an image upload for a file on disk. PUT the file’s raw bytes to the returned url before expiresAt, then call uploadMarketingImage with source: { uploadId } to compress and host it. Counts against the image upload quota.
  • createProductFilter — Save a product filter on this account. The returned id is what an email block stores.
  • createSampledSegment — Create a new static segment holding a random sample of up to sampleSize members of a static or dynamic segment. A source with fewer members is copied whole, and an empty source (or a dynamic one with no conditions) gives an empty segment. A dynamic source is sampled from the same periodically refreshed data as its memberCount, not live. The source is unchanged, and each call draws a new sample. Returns null if the caller owns no segment with that id. Fails with UNSUPPORTED_SEGMENT_TYPE for persona segments. The call waits for the write and can take over a minute for a large segment, so if it times out, look the segment up by name before retrying.
  • createSmsTemplate — Create an SMS template. trigger is required and cannot be UNKNOWN.
  • customerCustomFieldDeclarationCreate — Create a typed customer custom field declaration in this store’s catalog without writing a customer record. Idempotent when a declaration with the same name and dataType already exists; errors with CUSTOM_FIELD_TYPE_CONFLICT if one exists with a different dataType.
  • customerCustomFieldDeclarationDelete — Delete a customer custom field declaration from this store’s catalog. Returns true if an owned declaration was deleted, false if none matched.
  • deleteCampaign — Delete a campaign that has not started sending. Returns true if an owned campaign was deleted, false if none matched.
  • deleteDiscountCode — Delete a discount code. Returns true if an owned code was deleted, false if none matched. On Shopify the platform discount is deleted too; on BigCommerce only the Redo record is removed.
  • deleteEmailTemplate — Delete an email template. Returns true if an owned template was deleted, false if none matched.
  • deleteMarketingAutomation — Delete an automation and stop its in-flight runs. Returns true if an owned automation was deleted, false if none matched.
  • deleteProductFilter — Delete a product filter on this account. Returns false when the id is missing or belongs to another account. Interactive cart sections on this account that stored the id have that reference cleared.
  • deleteSegment — Delete a segment. Returns true if an owned segment was deleted, false if none matched.
  • deleteSmsTemplate — Delete an SMS template. Returns true if an owned template was deleted, false if none matched.
  • duplicateCampaign — Copy a campaign into a new draft: its audience, tags, sender, follow-up email and send settings, and a new copy of each email or SMS variant. The copy has no schedule and sends nothing until updateCampaign schedules it. Returns null if no campaign with that id is owned by the caller.
  • duplicateMarketingAutomation — Copy an automation into a new automation that is off: its steps, and a new copy of each email or SMS template, Recover config and Commerce Agent strategy they use. Turn the copy on with updateMarketingAutomation. Returns null if no owned automation matches the id.
  • emailDomainCreate — Add a domain the store sends email from, and start verifying it with the email provider. Publish its dnsRecords at the store’s DNS provider, then call emailDomainVerify. Errors with INVALID_DOMAIN if it isn’t a valid domain, DOMAIN_UNAVAILABLE if another store uses it, and DOMAIN_ALREADY_REGISTERED if the email provider already has it.
  • emailDomainDelete — Remove an email domain from the store, along with the store’s sender addresses on it. Returns true if a domain of the store was removed, false if none matched. Errors with EMAIL_DOMAIN_IN_USE while a support email sender sends through it; remove those senders first.
  • emailDomainMailFromSet — Set the MAIL FROM domain bounces return through, as a subdomain of the email domain, and start verifying it. Publish the MAIL FROM records in dnsRecords, then call emailDomainVerify. Returns null if no domain of the store matches the id. Errors with INVALID_SUBDOMAIN if the subdomain isn’t a single DNS label.
  • emailDomainVerify — Check the domain’s DNS records and verification with the email provider now, instead of waiting for the next background check. A domain checked in the last few seconds isn’t checked again. Returns null if no domain of the store matches the id.
  • emailSenderCreate — Add a sender address the store can use as a campaign From or Reply-To address. Errors with INVALID_EMAIL if email isn’t a full address, INVALID_LOCAL_PART if the part before the @ has invalid characters or dots, INVALID_DOMAIN if the domain isn’t valid, DOMAIN_UNAVAILABLE if another store has registered the domain, and EMAIL_SENDER_EXISTS if the store already has the address with this name.
  • emailSenderDelete — Remove a sender address. Returns true if an owned sender address was removed, false if none matched. Errors with EMAIL_SENDER_IS_DEFAULT if the address is the store’s default sender or reply-to; choose another default first.
  • emailSenderSendVerification — Email a sender address a link that confirms it receives email. Opening the link in the Redo dashboard sets its mailboxVerifiedAt. Returns null if no owned sender address matches the id. Errors with NOT_A_MAILBOX unless the address is marked as a mailbox, and with ALREADY_VERIFIED if it is verified.
  • emailSenderUpdate — Change a sender address’s display name or whether it can receive email. Returns null if no owned sender address matches the id. Errors with EMAIL_SENDER_EXISTS if the store already has the address with the new name.
  • emailTemplateLocalizationSave — Set an email template’s source language and save its translations. Each language in translations replaces that language’s saved copy, and each in deleteLocales is deleted; other saved languages are kept. Select localization on the result to read them back. Returns null if no owned template matches the id. Throws a 400 error with an extension code of INVALID_EMAIL_TEMPLATE_TRANSLATION when a language repeats, is the source language, a key is not in localization.entries, or a translation drops or breaks an HTML tag or {{ }} placeholder of the source; DUPLICATE_TRANSLATION_KEY when a key repeats within a language; and TOO_MANY_LANGUAGES past 20 languages. A request rejected with one of these errors saves nothing. Editing the template’s source text later re-translates every saved language in full, replacing hand-edited strings.
  • emailTemplateSendTest — Send a test email of a saved template, one email per address, as the template builder’s Send test email does. Sends the saved template, not unsaved edits. Takes up to 20 addresses per call, and counts toward the store’s 100 test recipients per day, shared with the Redo app. orderNumber fills the email with that order’s data, or with its return or Try-first contract for those templates; when it is omitted or matches nothing, the email carries sample data (see sampleData). A call that fails may already have sent to some addresses. Returns null if no template with that id is owned by the caller.
  • emailTemplateTranslate — Draft translations of an email template’s copy into other languages, for review. Nothing is saved: pass the drafts you keep, edited or not, to emailTemplateLocalizationSave. A language the translator could not produce safely comes back with no texts. Returns null if no owned template matches the id. Throws a 400 error with an extension code of INVALID_EMAIL_TEMPLATE_TRANSLATION when targetLocales repeats a language or includes sourceLocale, and TOO_MANY_LANGUAGES past 20 languages.
  • marketingContactsSuppress — Stop this store’s marketing to up to 100 email addresses and phone numbers, whether or not they belong to a customer yet. Consent status is unchanged. Returns one result per distinct contact, emails first, in the order given. INVALID_EMAIL or INVALID_PHONE_NUMBER (400) when any contact can’t be read, and then nothing is changed.
  • marketingContactsUnsuppress — Lift this store’s suppression of up to 100 email addresses and phone numbers. Contacts Redo suppresses for every store are left as they are and reported as SUPPRESSED_FOR_ALL_STORES. Returns one result per distinct contact, emails first, in the order given. INVALID_EMAIL or INVALID_PHONE_NUMBER (400) when any contact can’t be read, and then nothing is changed.
  • marketingEmailSettingsUpdate (Experimental) — Set the store’s default From and Reply-To addresses for marketing emails, as on the email domain settings page. Errors with INVALID_SENDER_ID if an id isn’t one of the store’s addresses, and with SENDER_DOMAIN_NOT_VERIFIED if the default sender isn’t on a DKIM-verified domain.
  • orderLookupCreate — Create the store’s Shopify order-lookup embed with default settings when none exists, or return the existing embed.
  • productBackInStockNotify — Queues a back-in-stock send for every subscriber still waiting on this product. Sends asynchronously. When a send for this variant is already running, this call adds nobody and reports ALREADY_RUNNING. Returns null if no product with that id is owned by the caller.
  • revertMarketingAutomation — Revert a store’s customized Return tracking automation to Redo’s default by deleting the store’s version. Redo’s default for that trigger runs again once the store has no other automation, on or off, for the trigger. Runs of the store’s version already in progress finish. Returns true if an owned automation was reverted, false if none matched. Errors with AUTOMATION_NOT_REVERTIBLE if the automation is not a customized Redo default.
  • segmentsDelete — Delete several segments at once, with their snapshots; a static segment’s members lose that membership. This cannot be undone. Returns the passed ids that matched one of the store’s segments and were deleted; other ids are skipped. Fails with CANNOT_DELETE_PROTECTED_SEGMENT, deleting nothing, if the list holds the Texas SMS exclusion segment. If the call fails partway, some segments may already be deleted; repeating it is safe.
  • smsKeywordCreate (Experimental) — Create an active SMS subscribe keyword. A customer who texts it to the store’s number is subscribed to SMS marketing and given its tags.
  • smsKeywordDelete (Experimental) — Delete an SMS keyword. Texting it no longer subscribes anyone; customers it already subscribed stay subscribed. Returns true if a keyword in this store was deleted, false if none has the id.
  • smsKeywordUpdate (Experimental) — Change an SMS keyword’s text or tags, or pause or resume it with status. Returns null if no keyword in this store has the id.
  • trackingPageCreate — Create a tracking page with default layout blocks and the given name.
  • trackingPageDelete — Delete a tracking page and return its snapshot prior to deletion. Returns null if no owned tracking page matches.
  • trackingPageDuplicate — Duplicate a tracking page as stored, naming the copy ”${name} (Copy)”. Returns null if no owned tracking page matches.
  • trackingPageSetDefault — Set a tracking page as the store’s default, clearing isDefault on the store’s other pages. Returns null if no owned tracking page matches.
  • trackingPageUpdate — Update a tracking page’s name or blocks. Returns null if no owned tracking page matches the id.
  • updateCampaign — Update a campaign. Returns null if no campaign with that id is owned by the caller.
  • updateCommerceAgentStrategy — Update a Commerce Agent strategy. Guidance is staged in the strategy’s draft, and agents keep using the published guidance until commerceAgentStrategyPublish publishes it; name and discountCodeId change the strategy at once. Returns null when this store has no strategy with that id.
  • updateCustomerTag — Rename a customer tag. Returns null if no owned tag matches the id.
  • updateDiscountCode — Update a discount code. Returns null if no code with that id is owned by the caller.
  • updateDynamicSegment — Update a dynamic segment. Returns null if no owned segment matches the id.
  • updateEmailTemplate — Update template metadata and/or apply section operations. Returns null if no owned template matches the id. Pass input, operations, or both.
  • updateMarketingAutomation — Update automation metadata and/or apply step operations. Returns null if no owned automation matches the id. Pass input, operations, or both. Turn it off with stopActiveRuns: true to also stop its runs in progress.
  • updateProductFilter — Replace a product filter on this account. An id from another account, or one that does not exist, is null.
  • updateSmsTemplate — Update an SMS template. Returns null if no owned template matches the id.
  • uploadMarketingImage — Upload an image for an SMS or email template. Redo checks the real file type, then resizes and compresses it with the same settings as the template editors, and returns a hosted URL. Each upload costs query points by size and also counts against a per-account upload quota; over the quota returns THROTTLED.

Objects

Interfaces

  • MessageAnalytics — Counts and rates for a marketing send over a period. Rates are fractions rather than percentages, and are null when the denominator is zero. Counts cover events that happened inside the range, which for an automation may include engagement with messages sent before it — so a rate can exceed 1.
  • ProductFilter — A named product recommendation rule saved on this account. id is the 24-character hex an email block stores as recommendedProductFilterId or productFilterId. It is not a catalog product id.

Input objects

Enums