Integration Specifications

This article will help you learn about how Daasity replicates data from Stay Ai, limitations to the data we can extract, and where the data is stored in the stay_ai schema

Integration Overview

Stay Ai is a subscription platform for e-commerce brands. Our integration extracts and loads the contents of those subscriptions.

This document provides context on what kind of data is being gathered through this extractor, which endpoints that data is coming from, and how the extracted tables relate to each other.

Integration Availability

This integration is currently available for:

  • Enterprise

API Endpoints

The Daasity Stay Ai extractor is built based on this API documentation. The following endpoints are used by Daasity to replicate data into your data warehouse:

Stay Ai Schema

The Daasity Okendo extractor creates these tables using the endpoints and replication methods listed. The data is mapped from source API endpoint to the table based on the mapping logic outlined in each table.

Subscriptions

  • Endpoint: List All Subscriptions

  • Update Method: UPSERT

  • Table Name: [stay_ai.subscriptions]

JSON ElementColumn

$.cancellationReason

cancellation_reason

$.cancelledAt

cancelled_at

$.churnedAt

churned_at

$.createdAt

created_at

$.currency

currency

$.customerId

customer_id

$.deliveryAddress.address1

delivery_address__address1

$.deliveryAddress.address2

delivery_address__address2

$.deliveryAddress.city

delivery_address__city

$.deliveryAddress.company

delivery_address__company

$.deliveryAddress.country

delivery_address__country

$.deliveryAddress.countryCode

delivery_address__country_code

$.deliveryAddress.firstName

delivery_address__first_name

$.deliveryAddress.lastName

delivery_address__last_name

$.deliveryAddress.phone

delivery_address__phone

$.deliveryAddress.province

delivery_address__province

$.deliveryAddress.provinceCode

delivery_address__province_code

$.deliveryAddress.zip

delivery_address__zip

$.deliveryPrice

delivery_price

$.dunningExitedAt

dunning_exited_at

$.dunningStartedAt

dunning_started_at

$.emailAddress

email_address

$.firstName

first_name

$.id

id

$.lastChargeDate

last_charge_date

$.lastName

last_name

$.nextBillingDate

next_billing_date

$.orderIntervalFrequency

order_interval_frequency

$.orderIntervalUnit

order_interval_unit

$.pausedUntil

paused_until

$.price

price

$.status

status

$.subscriptionId

subscription_id

$.updatedAt

updated_at

MD5($.id)

__sync_key

Subscription Line Items

  • Endpoint: List All Subscriptions

  • Update Method: UPSERT

  • Table Name: [stay_ai.subscription_line_items]

JSON ElementColumn

$.lineItems[].isOneTime

is_one_time

$.lineItems[].lineId

line_id

$.lineItems[].productTitle

product_title

$.lineItems[].quantity

quantity

$.lineItems[].shopifyProductId

shopify_product_id

$.lineItems[].shopifyVariantId

shopify_variant_id

$.lineItems[].sku

sku

$.lineItems[].subscriptionId

subscription_id

$.lineItems[].subtotalPrice

subtotal_price

$.lineItems[].unitPrice

unit_price

$.lineItems[].variantTitle

variant_title

MD5($.lineItems[].line_id + $.lineItems[].subscription_id)

__sync_key

Orders

  • Endpoint: List All Orders

  • Update Method: UPSERT

  • Table Name: [stay_ai.orders]

JSON ElementColumn

$.customerId

customer_id

$.address.address1

address__address1

$.address.address2

address__address2

$.address.city

address__city

$.address.company

address__company

$.address.country

address__country

$.address.countryCode

address__country_code

$.address.firstName

address__first_name

$.address.lastName

address__last_name

$.address.phone

address__phone

$.address.province

address__province

$.address.provinceCode

address__province_code

$.address.zip

address__zip

$.cartDiscountAmount

cart_discount_amount

$.createdAt

created_at

$.currency

currency

$.currentTotalTax

current_total_tax

$.customerId

customer_id

$.fulfillmentStatus

fulfillment_status

$.orderId

order_id

$.orderName

order_name

$.subscriptionId

subscription_id

$.tags

tags

$.totalPrice

total_price

$.totalShippingPrice

total_shipping_price

$.updatedAt

updated_at

MD5($.order_id)

__sync_key 

Order Line Items

  • Endpoint: List All Orders

  • Update Method: UPSERT

  • Table Name: [stay_ai.order_line_items]

$.lineItems[].lineIdline_id

$.lineItems[].productTitle

product_title

$.lineItems[].quantity

quantity

$.lineItems[].shopifyProductId

shopify_product_id

$.lineItems[].shopifyVariantId

shopify_variant_id

$.lineItems[].sku

sku

$.lineItems[].subtotalPrice

subtotal_price

$.lineItems[].variantTitle

variant_title

$.customerId

customer_id

$.orderId

order_id

$.subscriptionId

subscription_id

MD5($.lineItems[].line_id)

__sync_key

Last updated