5 minute read
September 15, 2023

Introduction to the DiVA API

The Data insights, Visualization, and Analytics (DiVA) API enables data-driven decisions for your business by aggregating and curating your production data in the Marqeta platform. The API includes view endpoints, which give you programmatic access to the data behind Marqeta reporting and analytics tools.

With the DiVA API, you can retrieve large datasets in JSON or CSV bulk file format. The request syntax supports filters, sorting, aggregation, and pagination, enabling you to customize the response as necessary to monitor and react to cardholder behavior.

The DiVA API is RESTful, meaning that it provides resource-oriented URLs, uses HTTP verbs to perform operations on resources, and uses HTTP response codes to indicate API errors.

The Marqeta platform provides two APIs—the DiVA API and the Core API. The Core API lets you manage your card payments program (for example, create users, issue cards, control spending, and retrieve specific transactions). For information about the Core API, refer to the Core API Reference. For more on reporting, see About Reporting.

Data sync times

Report data, such as clearing and settlement data, is synchronized three times each day. For specific times, see Expected refresh and settlement timelines.

Rate limits

Requests from the DiVA API should not exceed 300 report requests per five-minute interval (one per second). For information on related errors, see Response codes in Errors DiVA API.

Accessing the DiVA API

All DiVA API endpoints use the same base URL:


The endpoints return data you are authorized to access based on the credentials you provide in your request. You must include the program query parameter and specify the name of your program with most requests. For more information, see Authentication.

Requests that do not include the data source as shown above will experience 4XX errors and rejected responses.

Understanding views

View endpoints provide access to aggregated data that is derived from activity on the Marqeta platform, such as transactions, cardholder balances, or card statistics. The endpoint URL is generally constructed from these components:

  • Type – type of data to retrieve.

  • Aggregation level – how the data is aggregated (for example, by day or by cardholder).

  • Response – format in which to return the data. The default response is a JSON object that contains the results set. You can also export the data to a CSV file or retrieve a JSON representation of the data schema.

  • Query filter – filter for which records to return. The default filter is by date, for a recent period of time based on when the query is run.

For example, to retrieve authorization transaction data aggregated by week as a CSV file, you send a GET request to the /views/authorizations/week/csv endpoint.

For more information about response formats and how to customize your query results, see Response Customization. To retrieve a list of available views, see Views.

Subscribe to our developer newsletter