Reference

Table Customers


Description

No description available

Supported Operations

Below section contains supported CRUD operations. Each operation is executed by some EndPoint behind the scene.
Method Supported Reference EndPoint
SELECT get_customers
INSERT create_customer
UPDATE update_customer
UPSERT
DELETE delete_customer
LOOKUP get_single_customer

Examples

SSIS

Use Stripe Connector in API Source component to read data or in API Destination component to read/write data:

Read from Customers table using API Source

API Source - Stripe
This connector support read/write operations for Stripe APIs
Stripe
Customers
Optional Parameters
Email Id
Created later than (yyyy-MM-dd)
Created on or later than (yyyy-MM-dd)
Created earlier than (yyyy-MM-dd)
Created on or earlier than (yyyy-MM-dd)
SSIS API Source - Read from table or endpoint

Read/write to Customers table using API Destination

API Destination - Stripe
This connector support read/write operations for Stripe APIs
Stripe
Customers
Select
Optional Parameters
Email Id
Created later than (yyyy-MM-dd)
Created on or later than (yyyy-MM-dd)
Created earlier than (yyyy-MM-dd)
Created on or earlier than (yyyy-MM-dd)
SSIS API Destination - Access table operation

ODBC application

Use these SQL queries in your ODBC application data source:

Get all Customers

Read all customers

SELECT * FROM Customers

Get a Customer

Read a customer

SELECT * FROM Customers
WHERE Id = 'abc'

Get Customers (Filter by Date)

Using date time requires yyyy-MM-dd format usage

SELECT * FROM Customers
WHERE Created > '2010-01-01'

Insert a Customer

Insert a customer

INSERT INTO Customers
([Name]
	, [Email]
	, [Description]
	, [Phone]
	, [Balance]
	, [AddressLine1]
	, [AddressLine2]
	, [AddressCity]
	, [AddressState]
	, [AddressCountry]
	, [AddressPostalCode]
	, [InvoicePrefix]
	)
VALUES('Cust-1'
	, 'email@abc.com'
	, 'Some desc'
	, '+1 222-333-4444'
	, 0
	, '55 Main St.'
	, 'Suite 100'
	, 'New York'
	, 'NY'
	, 'USA'
	, '07204' --JSON fragment 
	, 'INVC'
)

Update a Customer

Update a customer

UPDATE Customers
SET   Name='Cust1-Updated'
	, Email='a-updated@b.com'
	, Phone='+1 800-123-2345'
	, Description='Desc-updated'
	, AddressLine1='Line-1-upd'
	, AddressLine2='Line-2-upd'
	, AddressCity='SomeCity'
	, AddressState='NY'
	, AddressCountry='USA'
	, AddressPostalCode='112233'
	
	, ShippingPhone='+1 800-123-2345'
	, ShippingName='SHName-upd'
	, ShippingAddressLine1='Line-1-upd'
	, ShippingAddressLine2='Line-2-upd'
	, ShippingAddressCity='SomeCity'
	, ShippingAddressState='NY'
	, ShippingAddressCountry='USA'
	, ShippingAddressPostalCode='112233'
	
	, Balance=100	
WHERE Id='cus_IcUG2lD69ZHuol'

Delete a Customer

Delete a customer by Id

DELETE FROM Customers
WHERE Id = 'abc'

SQL Server

Use these SQL queries in SQL Server after you create a data source in Data Gateway:

Get all Customers

Read all customers

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];

Get a Customer

Read a customer

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers
WHERE Id = ''abc''';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];

Get Customers (Filter by Date)

Using date time requires yyyy-MM-dd format usage

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers
WHERE Created > ''2010-01-01''';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];

Insert a Customer

Insert a customer

DECLARE @MyQuery NVARCHAR(MAX) = 'INSERT INTO Customers
([Name]
	, [Email]
	, [Description]
	, [Phone]
	, [Balance]
	, [AddressLine1]
	, [AddressLine2]
	, [AddressCity]
	, [AddressState]
	, [AddressCountry]
	, [AddressPostalCode]
	, [InvoicePrefix]
	)
VALUES(''Cust-1''
	, ''email@abc.com''
	, ''Some desc''
	, ''+1 222-333-4444''
	, 0
	, ''55 Main St.''
	, ''Suite 100''
	, ''New York''
	, ''NY''
	, ''USA''
	, ''07204'' --JSON fragment 
	, ''INVC''
)';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];

Update a Customer

Update a customer

DECLARE @MyQuery NVARCHAR(MAX) = 'UPDATE Customers
SET   Name=''Cust1-Updated''
	, Email=''a-updated@b.com''
	, Phone=''+1 800-123-2345''
	, Description=''Desc-updated''
	, AddressLine1=''Line-1-upd''
	, AddressLine2=''Line-2-upd''
	, AddressCity=''SomeCity''
	, AddressState=''NY''
	, AddressCountry=''USA''
	, AddressPostalCode=''112233''
	
	, ShippingPhone=''+1 800-123-2345''
	, ShippingName=''SHName-upd''
	, ShippingAddressLine1=''Line-1-upd''
	, ShippingAddressLine2=''Line-2-upd''
	, ShippingAddressCity=''SomeCity''
	, ShippingAddressState=''NY''
	, ShippingAddressCountry=''USA''
	, ShippingAddressPostalCode=''112233''
	
	, Balance=100	
WHERE Id=''cus_IcUG2lD69ZHuol''';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];

Delete a Customer

Delete a customer by Id

DECLARE @MyQuery NVARCHAR(MAX) = 'DELETE FROM Customers
WHERE Id = ''abc''';

EXEC (@MyQuery) AT [LS_TO_STRIPE_IN_GATEWAY];