Skip to content

feat: add streams Orders/Transactions/Subscriptions #2

@pnadolny13

Description

@pnadolny13
# Orders
# https://services.leadconnectorhq.com/payments/orders
# https://highlevel.stoplight.io/docs/integrations/378562f514a17-list-orders
schema = th.PropertiesList(
    th.Property("_id", th.StringType),
    th.Property("altId", th.StringType),
    th.Property("altType", th.StringType),
    th.Property("contactId", th.StringType),
    th.Property("contactName", th.StringType),
    th.Property("contactEmail", th.StringType),
    th.Property("currency", th.StringType),
    th.Property("amount", th.StringType),
    th.Property("subtotal", th.StringType),
    th.Property("discount", th.StringType),
    th.Property("status", th.StringType),
    th.Property("liveMode", th.StringType),
    th.Property("totalProducts", th.StringType),
    th.Property("sourceType", th.StringType),
    th.Property("sourceName", th.StringType),
    th.Property("sourceId", th.StringType),
    th.Property("sourceMeta", th.StringType),
    th.Property("couponCode", th.StringType),
    th.Property("createdAt", th.DateTimeType),
    th.Property("updatedAt", th.DateTimeType),
    th.Property("sourceSubType", th.StringType),
    th.Property("fulfillmentStatus", th.StringType),
    th.Property("onetimeProducts", th.StringType),
    th.Property("recurringProducts", th.StringType)
).to_dict()


# Transactions
# https://highlevel.stoplight.io/docs/integrations/4d127e6508f0a-list-transactions
schema = th.PropertiesList(
    th.Property("_id", th.StringType),
    th.Property("altId", th.StringType),
    th.Property("altType", th.StringType),
    th.Property("contactId", th.StringType),
    th.Property("contactName", th.StringType),
    th.Property("contactEmail", th.StringType),
    th.Property("currency", th.StringType),
    th.Property("amount", th.StringType),
    th.Property("status", th.StringType),
    th.Property("liveMode", th.StringType),
    th.Property("entityType", th.StringType),
    th.Property("entityId", th.StringType),
    th.Property("entitySourceType", th.StringType),
    th.Property("entitySourceSubType", th.StringType),
    th.Property("entitySourceName", th.StringType),
    th.Property("entitySourceId", th.StringType),
    th.Property("entitySourceMeta", th.StringType),
    th.Property("subscriptionId", th.StringType),
    th.Property("chargeId", th.StringType),
    th.Property("chargeSnapshot", th.StringType),
    th.Property("paymentProviderType", th.StringType),
    th.Property("paymentProviderConnectedAccount", th.StringType),
    th.Property("ipAddress", th.StringType),
    th.Property("createdAt", th.DateTimeType),
    th.Property("updatedAt", th.DateTimeType),
    th.Property("amountRefunded", th.StringType),
    th.Property("paymentMethod", th.StringType),
).to_dict()


# Subscriptions
# https://highlevel.stoplight.io/docs/integrations/33c965c6cb9da-list-subscriptions
schema = th.PropertiesList(
    th.Property("_id", th.StringType),
    th.Property("altId", th.StringType),
    th.Property("altType", th.StringType),
    th.Property("contactId", th.StringType),
    th.Property("contactName", th.StringType),
    th.Property("contactEmail", th.StringType),
    th.Property("currency", th.StringType),
    th.Property("amount", th.StringType),
    th.Property("status", th.StringType),
    th.Property("liveMode", th.StringType),
    th.Property("entityType", th.StringType),
    th.Property("entityId", th.StringType),
    th.Property("entitySourceType", th.StringType),
    th.Property("entitySourceName", th.StringType),
    th.Property("entitySourceId", th.StringType),
    th.Property("entitySourceMeta", th.StringType),
    th.Property("subscriptionId", th.StringType),
    th.Property("subscriptionSnapshot", th.StringType),
    th.Property("paymentProviderType", th.StringType),
    th.Property("paymentProviderConnectedAccount", th.StringType),
    th.Property("ipAddress", th.StringType),
    th.Property("createdAt", th.DateTimeType),
    th.Property("updatedAt", th.DateTimeType)
).to_dict()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions