PayPal connector reference

Important

This feature is in Beta. To use it, a workspace admin must turn on Lakeflow Connect for PayPal from the Previews page. See Manage Azure Databricks previews.

This page has reference information for the managed PayPal connector, including supported source tables and destination table schemas.

Supported source tables

The PayPal connector supports the following source tables, all under the default source schema:

Source table Primary key Description Sync mode Cursor field
transaction transaction_id, transaction_event_code Account transactions from the PayPal transaction search API, one row per transaction event. Incremental transaction_initiation_date
dispute dispute_id Customer disputes, claims, and chargebacks with full dispute details. Incremental update_time
invoice id Invoices with their details, recipients, items, payments, and refunds. Incremental last_update_time
balance account_id, currency Current account balances, one row per currency. Full refresh only
product id Catalog products. Full refresh only
billing_plan id Subscription billing plans. Full refresh only

Connector options

For usage, see Examples.

Option Type Scope Required Applies to Description
start_datetime String Pipeline No transaction, dispute, invoice Earliest date and time from which to ingest data, in yyyy-MM-ddTHH:mm:ssZ format (for example, 2024-01-01T00:00:00Z). Applies only to the first sync of each table; later syncs resume from the stored cursor. If you don't set it, transaction starts about 3 years back, dispute starts 179 days back, and invoice starts 5 years back. Values earlier than PayPal's retention window are moved forward to 3 years for transaction and 179 days for dispute.

Destination table schemas

transaction

Primary key: transaction_id, transaction_event_code Cursor field: transaction_initiation_date

Field Data type
transaction_id STRING
transaction_event_code STRING
transaction_initiation_date TIMESTAMP
transaction_updated_date TIMESTAMP
transaction_info STRUCT<paypal_account_id: STRING, transaction_id: STRING, paypal_reference_id: STRING, paypal_reference_id_type: STRING, transaction_event_code: STRING, transaction_initiation_date: TIMESTAMP, transaction_updated_date: TIMESTAMP, transaction_amount: STRUCT<currency_code: STRING, value: STRING>, fee_amount: STRUCT<currency_code: STRING, value: STRING>, discount_amount: STRUCT<currency_code: STRING, value: STRING>, insurance_amount: STRUCT<currency_code: STRING, value: STRING>, sales_tax_amount: STRUCT<currency_code: STRING, value: STRING>, shipping_amount: STRUCT<currency_code: STRING, value: STRING>, shipping_discount_amount: STRUCT<currency_code: STRING, value: STRING>, shipping_tax_amount: STRUCT<currency_code: STRING, value: STRING>, other_amount: STRUCT<currency_code: STRING, value: STRING>, tip_amount: STRUCT<currency_code: STRING, value: STRING>, transaction_status: STRING, transaction_subject: STRING, transaction_note: STRING, payment_tracking_id: STRING, bank_reference_id: STRING, ending_balance: STRUCT<currency_code: STRING, value: STRING>, available_balance: STRUCT<currency_code: STRING, value: STRING>, invoice_id: STRING, custom_field: STRING, protection_eligibility: STRING, credit_term: STRING, credit_transactional_fee: STRUCT<currency_code: STRING, value: STRING>, credit_promotional_fee: STRUCT<currency_code: STRING, value: STRING>, annual_percentage_rate: STRING, payment_method_type: STRING, instrument_type: STRING, instrument_sub_type: STRING>
payer_info STRUCT<account_id: STRING, email_address: STRING, phone_number: STRUCT<country_code: STRING, national_number: STRING, extension_number: STRING>, address_status: STRING, payer_status: STRING, payer_name: STRUCT<prefix: STRING, given_name: STRING, surname: STRING, middle_name: STRING, suffix: STRING, alternate_full_name: STRING, full_name: STRING>, country_code: STRING, address: STRUCT<line1: STRING, line2: STRING, city: STRING, state: STRING, country_code: STRING, postal_code: STRING>>
shipping_info STRUCT<name: STRING, method: STRING, address: STRUCT<line1: STRING, line2: STRING, city: STRING, state: STRING, country_code: STRING, postal_code: STRING>, secondary_shipping_address: STRUCT<line1: STRING, line2: STRING, city: STRING, state: STRING, country_code: STRING, postal_code: STRING>>
cart_info STRUCT<item_details: ARRAY<STRUCT<item_code: STRING, item_name: STRING, item_description: STRING, item_options: STRING, item_quantity: STRING, item_unit_price: STRUCT<currency_code: STRING, value: STRING>, item_amount: STRUCT<currency_code: STRING, value: STRING>, discount_amount: STRUCT<currency_code: STRING, value: STRING>, adjustment_amount: STRUCT<currency_code: STRING, value: STRING>, gift_wrap_amount: STRUCT<currency_code: STRING, value: STRING>, tax_percentage: STRING, tax_amounts: ARRAY<STRUCT<tax_amount: STRUCT<currency_code: STRING, value: STRING>>>, basic_shipping_amount: STRUCT<currency_code: STRING, value: STRING>, extra_shipping_amount: STRUCT<currency_code: STRING, value: STRING>, handling_amount: STRUCT<currency_code: STRING, value: STRING>, insurance_amount: STRUCT<currency_code: STRING, value: STRING>, total_item_amount: STRUCT<currency_code: STRING, value: STRING>, invoice_number: STRING, checkout_options: ARRAY<STRUCT<checkout_option_name: STRING, checkout_option_value: STRING>>>>, tax_inclusive: BOOLEAN, paypal_invoice_id: STRING>
store_info STRUCT<store_id: STRING, terminal_id: STRING>
auction_info STRUCT<auction_site: STRING, auction_item_site: STRING, auction_buyer_id: STRING, auction_closing_date: TIMESTAMP>
incentive_info STRUCT<incentive_details: ARRAY<STRUCT<incentive_type: STRING, incentive_code: STRING, incentive_amount: STRUCT<currency_code: STRING, value: STRING>, incentive_program_code: STRING>>>
last_refreshed_datetime TIMESTAMP
account_number STRING

dispute

Primary key: dispute_id Cursor field: update_time

Field Data type
dispute_id STRING
create_time TIMESTAMP
update_time TIMESTAMP
disputed_transactions ARRAY<STRUCT<buyer_transaction_id: STRING, seller_transaction_id: STRING, reference_id: STRING, create_time: TIMESTAMP, transaction_status: STRING, gross_amount: STRUCT<currency_code: STRING, value: STRING>, gross_asset: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>, invoice_number: STRING, custom: STRING, buyer: STRUCT<name: STRING, email: STRING, payer_id: STRING>, seller: STRUCT<email: STRING, merchant_id: STRING, name: STRING>, items: ARRAY<STRUCT<item_id: STRING, item_name: STRING, item_description: STRING, item_quantity: STRING, partner_transaction_id: STRING, reason: STRING, dispute_amount: STRUCT<currency_code: STRING, value: STRING>, notes: STRING, item_type: STRING, product_details: VARIANT, service_details: VARIANT, booking_details: VARIANT, digital_download_details: VARIANT, cancellation_details: VARIANT, agreed_refund_details: VARIANT>>, payment_processor: VARIANT, seller_protection_eligible: BOOLEAN, seller_protection_type: STRING>>
reason STRING
status STRING
dispute_state STRING
dispute_amount STRUCT<currency_code: STRING, value: STRING>
dispute_asset STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>
fee_policy VARIANT
external_reason_code STRING
dispute_outcome STRUCT<outcome_code: STRING, outcome_reason: STRING, amount_refunded: STRUCT<currency_code: STRING, value: STRING>, asset_refunded: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>>
adjudications ARRAY<STRUCT<type: STRING, adjudication_time: TIMESTAMP, reason: STRING, dispute_life_cycle_stage: STRING>>
money_movements ARRAY<STRUCT<affected_party: STRING, amount: STRUCT<currency_code: STRING, value: STRING>, asset: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>, initiated_time: TIMESTAMP, type: STRING, reason: STRING>>
fund_movements ARRAY<STRUCT<party: STRING, amount: STRUCT<currency_code: STRING, value: STRING>, asset: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>, initiated_time: TIMESTAMP, type: STRING, reason: STRING>>
dispute_life_cycle_stage STRING
dispute_channel STRING
messages ARRAY<STRUCT<posted_by: STRING, time_posted: TIMESTAMP, content: STRING, documents: ARRAY<STRUCT<name: STRING, url: STRING>>>>
extensions STRUCT<merchant_contacted: BOOLEAN, merchant_contacted_outcome: STRING, merchant_contacted_time: TIMESTAMP, merchant_contacted_mode: STRING, buyer_contacted_time: TIMESTAMP, buyer_contacted_channel: STRING, billing_dispute_properties: STRUCT<duplicate_transaction: STRUCT<received_duplicate: BOOLEAN, original_transaction: STRUCT<buyer_transaction_id: STRING, seller_transaction_id: STRING, reference_id: STRING, create_time: TIMESTAMP, transaction_status: STRING, gross_amount: STRUCT<currency_code: STRING, value: STRING>, gross_asset: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>, invoice_number: STRING, custom: STRING, buyer: STRUCT<name: STRING, email: STRING, payer_id: STRING>, seller: STRUCT<email: STRING, merchant_id: STRING, name: STRING>, items: ARRAY<STRUCT<item_id: STRING, item_name: STRING, item_description: STRING, item_quantity: STRING, partner_transaction_id: STRING, reason: STRING, dispute_amount: STRUCT<currency_code: STRING, value: STRING>, notes: STRING, item_type: STRING, product_details: VARIANT, service_details: VARIANT, booking_details: VARIANT, digital_download_details: VARIANT, cancellation_details: VARIANT, agreed_refund_details: VARIANT>>, payment_processor: VARIANT, seller_protection_eligible: BOOLEAN, seller_protection_type: STRING>>, incorrect_transaction_amount: STRUCT<correct_transaction_amount: STRUCT<currency_code: STRING, value: STRING>, correct_transaction_asset: STRUCT<asset_symbol: STRING, quantity: STRING, quantity_in_subunits: STRING, decimals: INT>, correct_transaction_time: TIMESTAMP>, payment_by_other_means: STRUCT<charge_different_from_original: BOOLEAN, received_duplicate: BOOLEAN, payment_method: STRING, payment_instrument_suffix: STRING>, credit_not_processed: STRUCT<issue_type: STRING, expected_refund: STRUCT<currency_code: STRING, value: STRING>, cancellation_details: STRUCT<cancellation_date: TIMESTAMP, cancellation_number: STRING, cancelled: BOOLEAN, cancellation_mode: STRING>, product_details: STRUCT<description: STRING, product_received: STRING, product_received_time: TIMESTAMP, expected_delivery_date: TIMESTAMP, sub_reasons: ARRAY<STRING>, purchase_url: STRING, return_details: STRUCT<return_time: TIMESTAMP, mode: STRING, receipt: BOOLEAN, return_confirmation_number: STRING, returned: BOOLEAN>>, service_details: STRUCT<description: STRING, service_started: STRING, note: STRING, sub_reasons: ARRAY<STRING>, purchase_url: STRING>, agreed_refund_details: STRUCT<merchant_agreed_refund: BOOLEAN, merchant_agreed_refund_time: TIMESTAMP>>, canceled_recurring_billing: STRUCT<expected_refund: STRUCT<currency_code: STRING, value: STRING>, cancellation_details: STRUCT<cancellation_date: TIMESTAMP, cancellation_number: STRING, cancelled: BOOLEAN, cancellation_mode: STRING>>>, merchandize_dispute_properties: STRUCT<issue_type: STRING, product_details: STRUCT<description: STRING, product_received: STRING, product_received_time: TIMESTAMP, expected_delivery_date: TIMESTAMP, sub_reasons: ARRAY<STRING>, purchase_url: STRING, return_details: STRUCT<return_time: TIMESTAMP, mode: STRING, receipt: BOOLEAN, return_confirmation_number: STRING, returned: BOOLEAN>>, service_details: STRUCT<description: STRING, service_started: STRING, note: STRING, sub_reasons: ARRAY<STRING>, purchase_url: STRING>, cancellation_details: STRUCT<cancellation_date: TIMESTAMP, cancellation_number: STRING, cancelled: BOOLEAN, cancellation_mode: STRING>, return_shipping_address: STRUCT<address_line_1: STRING, address_line_2: STRING, address_line_3: STRING, admin_area_4: STRING, admin_area_3: STRING, admin_area_2: STRING, admin_area_1: STRING, postal_code: STRING, country_code: STRING, address_details: STRUCT<street_number: STRING, street_name: STRING, street_type: STRING, delivery_service: STRING, building_name: STRING, sub_building: STRING>>>, reported_source: STRING>
evidences ARRAY<STRUCT<evidence_type: STRING, evidence_info: STRUCT<tracking_info: ARRAY<STRUCT<carrier_name: STRING, carrier_name_other: STRING, tracking_url: STRING, tracking_number: STRING>>, refund_ids: ARRAY<STRING>>, documents: ARRAY<STRUCT<name: STRING, url: STRING>>, notes: STRING, source: STRING, date: TIMESTAMP, item_id: STRING, item_type: STRING, action_info: STRUCT<action: STRING, response_option: STRING, mandatory: BOOLEAN>, dispute_life_cycle_stage: STRING>>
buyer_response_due_date TIMESTAMP
seller_response_due_date TIMESTAMP
offer STRUCT<buyer_requested_amount: STRUCT<currency_code: STRING, value: STRING>, seller_offered_amount: STRUCT<currency_code: STRING, value: STRING>, offer_type: STRING, history: ARRAY<STRUCT<offer_time: TIMESTAMP, actor: STRING, event_type: STRING, offer_type: STRING, offer_amount: STRUCT<currency_code: STRING, value: STRING>, notes: STRING, dispute_life_cycle_stage: STRING>>>
refund_details STRUCT<allowed_refund_amount: STRUCT<currency_code: STRING, value: STRING>>
communication_details STRUCT<email: STRING, note: STRING, time_posted: TIMESTAMP>
supporting_info ARRAY<STRUCT<notes: STRING, documents: ARRAY<STRUCT<name: STRING, url: STRING>>, source: STRING, provided_time: TIMESTAMP, dispute_life_cycle_stage: STRING>>
allowed_response_options STRUCT<acknowledge_return_item: STRUCT<acknowledgement_types: ARRAY<STRING>>, accept_claim: STRUCT<accept_claim_types: ARRAY<STRING>>, make_offer: STRUCT<offer_types: ARRAY<STRING>>>
links ARRAY<STRUCT<href: STRING, rel: STRING, method: STRING>>

Note

This table does not support SCD type 2 because it has VARIANT columns.

invoice

Primary key: id Cursor field: last_update_time

Field Data type
sequence_ts TIMESTAMP
last_update_time TIMESTAMP
id STRING
parent_id STRING
status STRING
detail STRUCT<reference: STRING, currency_code: STRING, note: STRING, terms_and_conditions: STRING, memo: STRING, attachments: ARRAY<STRUCT<id: STRING, reference_url: STRING, content_type: STRING, create_time: TIMESTAMP, size: STRING>>, invoice_number: STRING, invoice_date: DATE, payment_term: STRUCT<term_type: STRING, due_date: DATE>, archived: BOOLEAN, category_code: STRING, group_draft: BOOLEAN, viewed_by_recipient: BOOLEAN, metadata: STRUCT<create_time: TIMESTAMP, created_by: STRING, last_update_time: TIMESTAMP, last_updated_by: STRING, cancel_time: TIMESTAMP, cancelled_by: STRING, first_sent_time: TIMESTAMP, last_sent_time: TIMESTAMP, last_sent_by: STRING, created_by_flow: STRING, recipient_view_url: STRING, invoicer_view_url: STRING, caller_type: STRING>>
invoicer STRUCT<business_name: STRING, name: STRUCT<prefix: STRING, given_name: STRING, surname: STRING, middle_name: STRING, suffix: STRING, alternate_full_name: STRING, full_name: STRING>, address: STRUCT<address_line_1: STRING, address_line_2: STRING, address_line_3: STRING, admin_area_4: STRING, admin_area_3: STRING, admin_area_2: STRING, admin_area_1: STRING, postal_code: STRING, country_code: STRING, address_details: STRUCT<street_number: STRING, street_name: STRING, street_type: STRING, delivery_service: STRING, building_name: STRING, sub_building: STRING>>, email_address: STRING, phones: ARRAY<STRUCT<country_code: STRING, national_number: STRING, extension_number: STRING, phone_type: STRING>>, website: STRING, tax_id: STRING, additional_notes: STRING, logo_url: STRING>
primary_recipients ARRAY<STRUCT<billing_info: STRUCT<business_name: STRING, name: STRUCT<prefix: STRING, given_name: STRING, surname: STRING, middle_name: STRING, suffix: STRING, alternate_full_name: STRING, full_name: STRING>, address: STRUCT<address_line_1: STRING, address_line_2: STRING, address_line_3: STRING, admin_area_4: STRING, admin_area_3: STRING, admin_area_2: STRING, admin_area_1: STRING, postal_code: STRING, country_code: STRING, address_details: STRUCT<street_number: STRING, street_name: STRING, street_type: STRING, delivery_service: STRING, building_name: STRING, sub_building: STRING>>, email_address: STRING, phones: ARRAY<STRUCT<country_code: STRING, national_number: STRING, extension_number: STRING, phone_type: STRING>>, additional_info: STRING, language: STRING>, shipping_info: STRUCT<business_name: STRING, name: STRUCT<prefix: STRING, given_name: STRING, surname: STRING, middle_name: STRING, suffix: STRING, alternate_full_name: STRING, full_name: STRING>, address: STRUCT<address_line_1: STRING, address_line_2: STRING, address_line_3: STRING, admin_area_4: STRING, admin_area_3: STRING, admin_area_2: STRING, admin_area_1: STRING, postal_code: STRING, country_code: STRING, address_details: STRUCT<street_number: STRING, street_name: STRING, street_type: STRING, delivery_service: STRING, building_name: STRING, sub_building: STRING>>>>>
additional_recipients ARRAY<STRING>
items ARRAY<STRUCT<id: STRING, name: STRING, description: STRING, quantity: STRING, unit_amount: STRUCT<currency_code: STRING, value: STRING>, tax: STRUCT<name: STRING, percent: STRING, amount: STRUCT<currency_code: STRING, value: STRING>, tax_note: STRING>, item_date: DATE, discount: STRUCT<percent: STRING, amount: STRUCT<currency_code: STRING, value: STRING>>, unit_of_measure: STRING>>
configuration STRUCT<tax_calculated_after_discount: BOOLEAN, tax_inclusive: BOOLEAN, allow_tip: BOOLEAN, partial_payment: STRUCT<allow_partial_payment: BOOLEAN, minimum_amount_due: STRUCT<currency_code: STRING, value: STRING>>, has_conditional_rule: BOOLEAN, template_id: STRING, allow_only_pay_by_bank: BOOLEAN, allow_vba_payments: BOOLEAN, save_item_for_future: BOOLEAN>
amount STRUCT<currency_code: STRING, value: STRING, breakdown: STRUCT<item_total: STRUCT<currency_code: STRING, value: STRING>, discount: STRUCT<invoice_discount: STRUCT<percent: STRING, amount: STRUCT<currency_code: STRING, value: STRING>>, item_discount: STRUCT<currency_code: STRING, value: STRING>>, tax_total: STRUCT<currency_code: STRING, value: STRING>, shipping: STRUCT<amount: STRUCT<currency_code: STRING, value: STRING>, tax: STRUCT<name: STRING, percent: STRING, amount: STRUCT<currency_code: STRING, value: STRING>, tax_note: STRING>>, custom: STRUCT<label: STRING, amount: STRUCT<currency_code: STRING, value: STRING>>>>
due_amount STRUCT<currency_code: STRING, value: STRING>
gratuity STRUCT<currency_code: STRING, value: STRING>
payments STRUCT<paid_amount: STRUCT<currency_code: STRING, value: STRING>, transactions: ARRAY<STRUCT<type: STRING, payment_id: STRING, payment_date: DATE, payment_date_time: TIMESTAMP, method: STRING, note: STRING, amount: STRUCT<currency_code: STRING, value: STRING>, shipping_info: STRUCT<business_name: STRING, name: STRUCT<prefix: STRING, given_name: STRING, surname: STRING, middle_name: STRING, suffix: STRING, alternate_full_name: STRING, full_name: STRING>, address: STRUCT<address_line_1: STRING, address_line_2: STRING, address_line_3: STRING, admin_area_4: STRING, admin_area_3: STRING, admin_area_2: STRING, admin_area_1: STRING, postal_code: STRING, country_code: STRING, address_details: STRUCT<street_number: STRING, street_name: STRING, street_type: STRING, delivery_service: STRING, building_name: STRING, sub_building: STRING>>>>>>
refunds STRUCT<refund_amount: STRUCT<currency_code: STRING, value: STRING>, transactions: ARRAY<STRUCT<type: STRING, refund_id: STRING, recipient_transaction_id: STRING, refund_date: DATE, amount: STRUCT<currency_code: STRING, value: STRING>, method: STRING>>>
links ARRAY<STRUCT<href: STRING, rel: STRING, method: STRING>>
unilateral BOOLEAN

balance

Primary key: account_id, currency Sync mode: Full refresh only

Field Data type
currency STRING
primary BOOLEAN
total_balance STRUCT<currency_code: STRING, value: STRING>
available_balance STRUCT<currency_code: STRING, value: STRING>
withheld_balance STRUCT<currency_code: STRING, value: STRING>
account_id STRING
as_of_time TIMESTAMP
last_refresh_time TIMESTAMP

product

Primary key: id Sync mode: Full refresh only

Field Data type
id STRING
name STRING
description STRING
type STRING
category STRING
image_url STRING
home_url STRING
payee STRUCT<merchant_id: STRING, display_data: STRUCT<business_phone: STRUCT<country_code: STRING, national_number: STRING>>>
create_time TIMESTAMP
update_time TIMESTAMP
links ARRAY<STRUCT<href: STRING, rel: STRING, method: STRING>>

billing_plan

Primary key: id Sync mode: Full refresh only

Field Data type
id STRING
product_id STRING
name STRING
status STRING
description STRING
usage_type STRING
version INT
quantity_supported BOOLEAN
billing_cycles ARRAY<STRUCT<sequence: INT, tenure_type: STRING, total_cycles: INT, frequency: STRUCT<interval_unit: STRING, interval_count: INT>, pricing_scheme: STRUCT<version: INT, pricing_model: STRING, fixed_price: STRUCT<currency_code: STRING, value: STRING>, tiers: ARRAY<STRUCT<starting_quantity: STRING, ending_quantity: STRING, amount: STRUCT<currency_code: STRING, value: STRING>>>, create_time: TIMESTAMP, update_time: TIMESTAMP>>>
payment_preferences STRUCT<auto_bill_outstanding: BOOLEAN, setup_fee: STRUCT<currency_code: STRING, value: STRING>, setup_fee_failure_action: STRING, payment_failure_threshold: INT, service_type: STRING>
taxes STRUCT<percentage: STRING, inclusive: BOOLEAN>
payee STRUCT<merchant_id: STRING, display_data: STRUCT<business_email: STRING, business_phone: STRUCT<country_code: STRING, national_number: STRING>>>
create_time TIMESTAMP
update_time TIMESTAMP
links ARRAY<STRUCT<href: STRING, rel: STRING, method: STRING, encType: STRING>>

Required PayPal app features

The PayPal REST API app must have the following features enabled. To change them, open the app in Apps & Credentials in the PayPal Developer Dashboard and update its Features section.

Feature Required for
Transaction search transaction, balance
Invoicing invoice
Customer disputes dispute
Subscriptions product, billing_plan