Ready to get started?

Download a free trial of the Zuora Data Provider to get started:

 Download Now

Learn more:

Zuora Icon Zuora ADO.NET Provider

Rapidly create and deploy powerful .NET applications that integrate with Zuora.

DataBind Zuora Data to the DevExpress Data Grid



Use the CData ADO.NET Provider for Zuora with the DevExpress Windows Forms and Web controls to provide Zuora data to a chart.

The ADO.NET Provider for Zuora by CData incorporates conventional ADO.NET data access components compatible with third-party controls. You can adhere to the standard ADO.NET data binding procedures to establish two-way access to real-time data through UI controls. This article will demonstrate the utilization of CData components for data binding with DevExpress UI Controls (Windows Forms and Web controls), specifically binding to a chart that visualizes live data.

Zuora uses the OAuth standard to authenticate users. See the online Help documentation for a full OAuth authentication guide.

Configuring Tenant property

In order to create a valid connection with the provider you need to choose one of the Tenant values (USProduction by default) which matches your account configuration. The following is a list with the available options:

  • USProduction: Requests sent to https://rest.zuora.com.
  • USAPISandbox: Requests sent to https://rest.apisandbox.zuora.com"
  • USPerformanceTest: Requests sent to https://rest.pt1.zuora.com"
  • EUProduction: Requests sent to https://rest.eu.zuora.com"
  • EUSandbox: Requests sent to https://rest.sandbox.eu.zuora.com"

Selecting a Zuora Service

Two Zuora services are available: Data Query and AQuA API. By default ZuoraService is set to AQuADataExport.

DataQuery

The Data Query feature enables you to export data from your Zuora tenant by performing asynchronous, read-only SQL queries. We recommend to use this service for quick lightweight SQL queries.

Limitations
  • The maximum number of input records per table after filters have been applied: 1,000,000
  • The maximum number of output records: 100,000
  • The maximum number of simultaneous queries submitted for execution per tenant: 5
  • The maximum number of queued queries submitted for execution after reaching the limitation of simultaneous queries per tenant: 10
  • The maximum processing time for each query in hours: 1
  • The maximum size of memory allocated to each query in GB: 2
  • The maximum number of indices when using Index Join, in other words, the maximum number of records being returned by the left table based on the unique value used in the WHERE clause when using Index Join: 20,000

AQuADataExport

AQuA API export is designed to export all the records for all the objects ( tables ). AQuA query jobs have the following limitations:

Limitations
  • If a query in an AQuA job is executed longer than 8 hours, this job will be killed automatically.
  • The killed AQuA job can be retried three times before returned as failed.

Windows Forms Controls

The code below shows how to populate a DevExpress chart with Zuora data. The ZuoraDataAdapter binds to the Series property of the chart control. The Diagram property of the control defines the x- and y-axes as the column names.

using (ZuoraConnection connection = new ZuoraConnection( "OAuthClientID=MyOAuthClientId;OAuthClientSecret=MyOAuthClientSecret;Tenant=USProduction;ZuoraService=DataQuery;InitiateOAuth=GETANDREFRESH")) { ZuoraDataAdapter dataAdapter = new ZuoraDataAdapter( "SELECT Id, BillingCity FROM Invoices WHERE BillingState = 'CA'", connection); DataTable table = new DataTable(); dataAdapter.Fill(table); DevExpress.XtraCharts.Series series = new DevExpress.XtraCharts.Series(); chartControl1.Series.Add(series); series.DataSource = table; series.ValueDataMembers.AddRange(new string[] { "BillingCity" }); series.ArgumentScaleType = DevExpress.XtraCharts.ScaleType.Qualitative; series.ArgumentDataMember = "Id"; series.ValueScaleType = DevExpress.XtraCharts.ScaleType.Numerical; chartControl1.Legend.Visibility = DevExpress.Utils.DefaultBoolean.False; ((DevExpress.XtraCharts.SideBySideBarSeriesView)series.View).ColorEach = true; }

Web Controls

The code below shows how to populate a DevExpress Web control with Zuora data. The ZuoraDataAdapter binds to the Series property of the chart; the Diagram property defines the x- and y-axes as the column names.

using DevExpress.XtraCharts; using (ZuoraConnection connection = new ZuoraConnection( "OAuthClientID=MyOAuthClientId;OAuthClientSecret=MyOAuthClientSecret;Tenant=USProduction;ZuoraService=DataQuery;InitiateOAuth=GETANDREFRESH")) { ZuoraDataAdapter ZuoraDataAdapter1 = new ZuoraDataAdapter("SELECT Id, BillingCity FROM Invoices WHERE BillingState = 'CA'", connection); DataTable table = new DataTable(); ZuoraDataAdapter1.Fill(table); DevExpress.XtraCharts.Series series = new Series("Series1", ViewType.Bar); WebChartControl1.Series.Add(series); series.DataSource = table; series.ValueDataMembers.AddRange(new string[] { "BillingCity" }); series.ArgumentScaleType = ScaleType.Qualitative; series.ArgumentDataMember = "Id"; series.ValueScaleType = ScaleType.Numerical; ((DevExpress.XtraCharts.SideBySideBarSeriesView)series.View).ColorEach = true; }