Marqeta cards API
The cards API from Marqeta — 11 operation(s) for cards.
Operations 15
Documentation
Documentation
https://www.marqeta.com/docs/core-api
Documentation
https://www.marqeta.com/docs/diva-api
The cards API from Marqeta — 11 operation(s) for cards.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/marqeta-cards-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
contact:
email: support@marqeta.com
name: Marqeta
description: Marqeta's Core API endpoints, conveniently annotated to enable code generation (including SDKs), test cases, and documentation. Currently in beta.
termsOfService: https://www.marqeta.com/api-terms
title: Core accepted countries Cards API
version: 3.0.39
servers:
- url: /v3
security:
- mqAppAndAccessToken: []
tags:
- name: cards
paths:
/cards:
get:
operationId: getCards
parameters:
- description: Number of cards to retrieve
explode: true
in: query
name: count
required: false
schema:
default: 5
format: int32
type: integer
style: form
- description: Start index
explode: true
in: query
name: start_index
required: false
schema:
default: 0
format: int32
type: integer
style: form
- description: Last four digits of card number
explode: true
in: query
name: last_four
required: true
schema:
type: string
style: form
- description: Comma-delimited list of fields to return (e.g. field_1,field_2,..). Leave blank to return all fields.
explode: true
in: query
name: fields
required: false
schema:
type: string
style: form
- description: Sort order
explode: true
in: query
name: sort_by
required: false
schema:
default: -lastModifiedTime
type: string
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/CardListResponse'
description: Success
'400':
content: {}
description: Bad request
'500':
content: {}
description: Server error
summary: Lists cards by the last 4 digits
tags:
- cards
post:
operationId: postCards
parameters:
- description: Show CVV
explode: true
in: query
name: show_cvv_number
required: false
schema:
default: false
type: boolean
style: form
- description: Show PAN
explode: true
in: query
name: show_pan
required: false
schema:
default: false
type: boolean
style: form
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/card_request'
required: false
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/card_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'409':
content: {}
description: Token already associated with a different payload
'500':
content: {}
description: Server error
summary: Creates a card
tags:
- cards
/cards/barcode/{barcode}:
get:
operationId: getCardsBarcodeBarcode
parameters:
- description: Barcode
explode: false
in: path
name: barcode
required: true
schema:
type: string
style: simple
- description: Comma-delimited list of fields to return (e.g. field_1,field_2,..). Leave blank to return all fields.
explode: true
in: query
name: fields
required: false
schema:
type: string
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/card_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'404':
content: {}
description: Card does not exist
'500':
content: {}
description: Server error
summary: Returns a card's metadata
tags:
- cards
/cards/getbypan:
post:
operationId: postCardsGetbypan
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/pan_request'
required: false
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/pan_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'500':
content: {}
description: Server error
summary: Returns user and card tokens for the specified PAN
tags:
- cards
/cards/user/{token}:
get:
operationId: getCardsUserToken
parameters:
- description: User token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Number of items to retrieve
explode: true
in: query
name: count
required: false
schema:
default: 5
format: int32
type: integer
style: form
- description: Start index
explode: true
in: query
name: start_index
required: false
schema:
default: 0
format: int32
type: integer
style: form
- description: Comma-delimited list of fields to return (e.g. field_1,field_2,..). Leave blank to return all fields.
explode: true
in: query
name: fields
required: false
schema:
type: string
style: form
- description: Sort order
explode: true
in: query
name: sort_by
required: false
schema:
default: -lastModifiedTime
type: string
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/CardListResponse'
description: Success
'400':
content: {}
description: User input error/Bad request
'500':
content: {}
description: Server error
summary: Lists all cards for a specific user
tags:
- cards
/cards/{token}:
get:
operationId: getCardsToken
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Comma-delimited list of fields to return (e.g. field_1,field_2,..). Leave blank to return all fields.
explode: true
in: query
name: fields
required: false
schema:
type: string
style: form
- description: Object to expand
explode: true
in: query
name: expand
required: false
schema:
type: string
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/card_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'404':
content: {}
description: Card not found
'500':
content: {}
description: Server error
summary: Returns a specific card
tags:
- cards
put:
operationId: putCardsToken
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/card_update_request'
required: false
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/card_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'500':
content: {}
description: Server error
summary: Updates a specific card
tags:
- cards
/cards/{token}/showpan:
get:
operationId: getCardsTokenShowpan
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Comma-delimited list of fields to return (e.g. field_1,field_2,..). Leave blank to return all fields.
explode: true
in: query
name: fields
required: false
schema:
type: string
style: form
- explode: true
in: query
name: show_cvv_number
required: false
schema:
type: boolean
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/card_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'404':
content: {}
description: Card not found
'500':
content: {}
description: Server error
summary: Returns a specific card - PAN visible
tags:
- cards
/cards/{token}/stoporders:
get:
operationId: getStopOrders
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Number of stop orders to retrieve
explode: true
in: query
name: count
required: false
schema:
default: 5
format: int32
type: integer
style: form
- description: Start index
explode: true
in: query
name: start_index
required: false
schema:
default: 0
format: int32
type: integer
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/StopOrderListResponse'
description: Success
'404':
content: {}
description: Not found
'500':
content: {}
description: Server error
summary: Lists all stop orders for a card
tags:
- cards
post:
operationId: postStopOrders
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/stop_order_request'
required: false
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/stop_order_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'404':
content: {}
description: Not found
'409':
content: {}
description: Token already associated with a different payload
'500':
content: {}
description: Server error
summary: Creates a stop order for a card transaction
tags:
- cards
/cards/{token}/stoporders/{stop_order_token}:
get:
operationId: getStopOrder
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Stop order token
explode: false
in: path
name: stop_order_token
required: true
schema:
type: string
style: simple
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/stop_order_response'
description: Success
'404':
content: {}
description: Not found
'500':
content: {}
description: Server error
summary: Retrieves a specific stop order
tags:
- cards
put:
operationId: putStopOrders
parameters:
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: Stop order token
explode: false
in: path
name: stop_order_token
required: true
schema:
type: string
style: simple
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/stop_order_update_request'
required: false
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/stop_order_response'
description: Success
'400':
content: {}
description: User input error/Bad request
'404':
content: {}
description: Not found
'422':
content: {}
description: Unprocessable entity
'500':
content: {}
description: Server error
summary: Updates a stop order by token
tags:
- cards
/cards/{token}/transactions:
get:
operationId: getCardTransactions
parameters:
- description: Number of transactions to retrieve
explode: true
in: query
name: count
required: false
schema:
default: 10
format: int32
type: integer
style: form
- description: Start index
explode: true
in: query
name: start_index
required: false
schema:
default: 0
format: int32
type: integer
style: form
- description: Card token
explode: false
in: path
name: token
required: true
schema:
type: string
style: simple
- description: User token
explode: true
in: query
name: user_token
required: false
schema:
type: string
style: form
- description: Start date (yyyy-MM-dd | yyyy-MM-ddTHH:mm:ss.SS)
explode: true
in: query
name: start_date
required: false
schema:
type: string
style: form
- description: End date (yyyy-MM-dd | yyyy-MM-ddTHH:mm:ss.SS)
explode: true
in: query
name: end_date
required: false
schema:
type: string
style: form
- description: Filter by recurring transaction flag
explode: true
in: query
name: is_recurring
required: false
schema:
type: boolean
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/TransactionModelListResponse'
description: Success
'400':
content: {}
description: User input error/Bad request
'500':
content: {}
description: Server error
summary: Returns transactions for a specific card
tags:
- cards
/views/cards/{time_agg}:
get:
operationId: getCards
summary: Retrieve card state and history data
description: Returns card state and history data aggregated at card level or by time period. Use this endpoint to report on card issuance volume, card state distribution, and card activity across your program.
tags:
- cards
parameters:
- $ref: '#/components/parameters/time_agg'
- $ref: '#/components/parameters/program'
- $ref: '#/components/parameters/fields'
- $ref: '#/components/parameters/start_date'
- $ref: '#/components/parameters/end_date'
- $ref: '#/components/parameters/format'
- $ref: '#/components/parameters/limit'
- $ref: '#/components/parameters/offset'
responses:
'200':
description: Card data for the specified time period.
content:
application/json:
schema:
$ref: '#/components/schemas/CardsResponse'
text/csv:
schema:
type: string
description: CSV-formatted card data.
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
/views/cards/detail:
get:
operationId: getCardsDetail
summary: Retrieve detailed card information
description: Returns detailed information for each card in your program, including the full card lifecycle history, current state, expiration, and associated user. Use this endpoint for granular card-level reporting and auditing.
tags:
- cards
parameters:
- $ref: '#/components/parameters/program'
- $ref: '#/components/parameters/fields'
- $ref: '#/components/parameters/format'
- $ref: '#/components/parameters/limit'
- $ref: '#/components/parameters/offset'
responses:
'200':
description: Detailed card records.
content:
application/json:
schema:
$ref: '#/components/schemas/CardsDetailResponse'
text/csv:
schema:
type: string
description: CSV-formatted detailed card data.
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
components:
schemas:
text_value:
properties:
value:
description: Line of personalized text printed on the card.
type: string
type: object
jit_address_verification:
description: Contains address verification data used to make JIT Funding decisions.
properties:
gateway:
$ref: '#/components/schemas/address_verification_source'
issuer:
$ref: '#/components/schemas/address_verification_source'
request:
$ref: '#/components/schemas/avs_information'
type: object
auto_reload_model:
description: 'Contains information about an auto reload.
See <</core-api/auto-reload, Auto Reloads>> for more information.
Returned if an auto reload was executed.'
properties:
active:
default: true
description: 'Specifies whether the auto reload is active.
Only one auto reload per level, per object, can be active.'
type: boolean
association:
$ref: '#/components/schemas/auto_reload_association'
currency_code:
description: Three-digit link:https://www.iso.org/iso-4217-currency-codes.html[ISO 4217 currency code, window="_blank"].
type: string
funding_source_address_token:
description: 'Unique identifier of the funding source address to use for this auto reload.
If your funding source is an ACH account, then a `funding_source_address_token` is not required.
If your funding source is a payment card, you must have at least one funding source address in order to create a GPA order.
Send a `GET` request to `/fundingsources/addresses/user/{user_token}` to retrieve address tokens for a user.
Send a `GET` request to `/fundingsources/addresses/business/{business_token}` to retrieve address tokens for a business.'
maxLength: 36
minLength: 1
type: string
funding_source_token:
description: 'Unique identifier of the funding source to use for this auto reload.
Send a `GET` request to `/fundingsources/user/{user_token}` to retrieve funding source tokens for a user.
Send a `GET` request to `/fundingsources/business/{business_token}` to retrieve funding source tokens for a business.'
maxLength: 36
minLength: 1
type: string
order_scope:
$ref: '#/components/schemas/order_scope'
token:
description: 'Unique identifier of the auto reload.
If you do not include a token, the system will generate one automatically.
This token is necessary for use in other API calls, so we recommend that rather than let the system generate one, you use a simple string that is easy to remember.
This value cannot be updated.'
maxLength: 36
minLength: 1
type: string
required:
- currency_code
- order_scope
type: object
pos:
description: 'Contains information about the point of sale, including details on how the card was presented.
Returned if provided by the card network, and the request uses Transaction Model v2 of the Marqeta Core API.
Not returned for Transaction Model v1 requests.'
properties:
card_data_input_capability:
description: How the terminal accepts card data.
enum:
- UNKNOWN
- NO_TERMINAL
- MAG_STRIPE
- MAG_STRIPE_CONTACTLESS
- MAG_STRIPE_KEY_ENTRY
- CHIP
- CHIP_CONTACTLESS
- CHIP_MAG_STRIPE
- CHIP_MAG_STRIPE_KEY_ENTRY
- KEY_ENTRY
- OCR
- MICR
- BAR_CODE
- CREDENTIALS_ON_FILE
type: string
card_holder_presence:
default: false
description: Whether the cardholder was present during the transaction.
type: boolean
card_presence:
default: false
description: Whether the card was present during the transaction.
type: boolean
cardholder_authentication_method:
description: Method used to authenticate the cardholder.
enum:
- UNSPECIFIED
- NON_AUTHENTICATED
- SIGNATURE
- PIN
- ID_VERIFIED
- ELECTRONIC_SIGNATURE
- BIOMETRIC
- BIOGRAPHIC
- MANUAL_SIGNATURE
- ELECTRONIC_TICKET_ENVIRONMENT
type: string
country_code:
description: Country code of the card acceptor or terminal.
type: string
county:
description: County of the card acceptor or terminal.
type: string
is_installment:
default: false
description: Whether the transaction is an installment payment.
type: boolean
is_recurring:
default: false
description: Whether the transaction is recurring.
type: boolean
pan_entry_mode:
description: Method used for capturing the card primary account number (PAN) during the transaction.
enum:
- UNKNOWN
- MANUAL
- MAG_STRIPE
- MAG_STRIPE_CONTACTLESS
- BAR_CODE
- OCR
- MICR
- CHIP
- CHIP_CONTACTLESS
- CARD_ON_FILE
- CHIP_FALLBACK
- OTHER
- KEY_ENTERED
- CREDENTIALS_ON_FILE
- KEYED_CARD_PCSC
- MAG_STRIPE_READ_KEYED_PCSC
type: string
partial_approval_capable:
default: false
description: Indicates whether the card acceptor or terminal supports partial-approval transactions.
type: boolean
pin_entry_mode:
description: 'Indicates whether the card acceptor or terminal can capture card personal identification numbers (PINs).
*NOTE:* This field does not indicate whether a PIN was entered.'
enum:
- UNKNOWN
- 'TRUE'
- 'FALSE'
- DEFECTIVE
type: string
pin_present:
default: false
description: Indicates whether the cardholder entered a PIN during the transaction.
type: boolean
purchase_amount_only:
default: false
description: Indicates whether the card acceptor or terminal supports purchase-only approvals.
type: boolean
special_condition_indicator:
description: 'Indicates a higher-risk operation, such as a quasi-cash or cryptocurrency transaction.
These transactions typically involve non-financial institutions.'
enum:
- UNSPECIFIED
- CRYPTOCURRENCY_PURCHASE
- QUASI_CASH
- DEBT_PAYMENT
- CENTRAL_BANK_DIGITAL_CURRENCY_PURCHASE
- STABLECOIN_PURCHASE
- BLOCKCHAIN_NATIVE_TOKEN_PURCHASE
- NON_FUNGIBLE_TOKEN_PURCHASE
type: string
state:
description: State, province, or territory of the card acceptor or terminal.
type: string
terminal_attendance:
description: Whether the card acceptor/terminal was attended.
enum:
- UNSPECIFIED
- ATTENDED
- UNATTENDED
- NO_TERMINAL
- MOBILE_REMOTE
- TRANSIT_ACCESS_TERMINAL
type: string
terminal_id:
description: Card acceptor or terminal identification number.
type: string
terminal_location:
description: Location of the card acceptor/terminal.
enum:
- ON_PREMISE
- ON_PREMISE_CARDHOLDER
- OFF_PREMISE_CARDHOLDER
- ON_PREMISE_MERCHANT
- OFF_PREMISE_MERCHANT
- NO_TERMINAL
- MOBILE_REMOTE
- TRANSIT_ACCESS_TERMINAL
- UNSPECIFIED
type: string
terminal_type:
description: Type of card acceptor/terminal.
enum:
- AUTO_DISPENSER_WITH_PIN
- SELF_SERVICE
- LIMITED_AMOUNT
- IN_FLIGHT
- ECOMMERCE
- TRANSPONDER
type: string
transaction_initiated_by:
description: Specifies the initiator of the transaction.
enum:
- CONSUMER
- MERCHANT
- UNKNOWN
- MARQETA
- NETWORK
type: string
transaction_initiated_category:
description: Specifies the category of a point-of-sale transaction.
enum:
- CARD_ON_FILE
- RECURRING_VAR_AMT_FIXED_FREQ
- RECURRING_PAYMENT
- INSTALLMENT_PAYMENT
- UNSCHEDULED_PAYMENT
- PARTIAL_SHIPMENT
- DELAYED_PAYMENT
- NO_SHOW
- RESUBMISSION
- DEFERRED_BILLING
- ACCOUNT_INQUIRY
- INCREMENTAL_AUTHORIZATION
- REAUTHORIZATION
type: string
zip:
description: United States ZIP code of the card acceptor or terminal.
type: string
type: object
CardFulfillmentResponse:
description: Determines physical characteristics of a card and shipment information.
properties:
card_fulfillment_reason:
description: Descriptive reason for the card fulfillment.
enum:
- NEW
- LOST_STOLEN
- EXPIRED
type: string
card_personalization:
$ref: '#/components/schemas/card_personalization'
shipping:
$ref: '#/components/schemas/ShippingInformationResponse'
required:
- card_personalization
type: object
wallet_provider_profile:
description: Contains information held and provided by the digital wallet provider.
properties:
account:
$ref: '#/components/schemas/account'
device_score:
description: Score from the device.
type: string
pan_source:
description: Source from which the digital wallet provider obtained the card primary account number (PAN).
type: string
reason_code:
description: 'Reason for the wallet provider''s provisioning decision.
* *01* – Cardholder''s wallet account is too new relative to launch.
* *02* – Cardholder''s wallet account is too new relative to provisioning request.
* *03* – Cardholder''s wallet account/card pair is newer than date threshold.
* *04* – Changes made to account data within the account threshold.
* *05* – Suspicious transactions linked to this account.
* *06* – Account has not had activity in the last year.
* *07* – Suspended cards in the secure element.
* *08* – Device was put in lost mode in the last seven days for longer than the duration threshold.
* *09* – The number of provisioning attempts on this device in 24 hours exceeds threshold.
* *0A* – There have been more than the threshold number of different cards attempted at provisioning to this phone in 24 hours.
* *0B* – The card provisioning attempt contains a distinct name in excess of the threshold.
* *0C* – The device score is less than 3.
* *0D* – The account score is less than 4.
* *0E* – Device provisioning location outside of the cardholder''s wallet account home country.
* *0G* – Suspect fraud.'
type: string
recommendation_reasons:
description: Array of recommendation reasons from the digital wallet provider.
items:
type: string
type: array
risk_assessment:
$ref: '#/components/schemas/risk_assessment'
type: object
flex:
description: Contains information about a Flexible Credential transaction.
properties:
action:
description: Indicates whether the Flexible Credential transaction object is actionable (`inquiry`) or merely informative (`advice`).
enum:
- inquiry
- advice
type: string
eligible:
description: Indicates whether or not the transaction is eligible for Flexible Credential transactions.
type: string
eligible_products:
description: 'Specifies which of the payment instrument''s credentials is eligible for this transaction:
* A value of `DEBIT` indicates the primary credential.
* A value of `LOAN` indicates the secondary credential.'
items:
type: string
type: array
secondary_credential_identifier:
description: Identifies the secondary credential used in the transaction, if applicable.
type: string
selected_product:
description: Indicates the eligible product that was used in the transaction.
type: string
type: object
program_transfer_response:
description: Contains information about a program transfer, which moves funds from an account holder's GPA to a program funding source.
properties:
amount:
description: Amount of program transfer.
type: number
business_token:
description: 'Unique identifier of the business account holder.
Returned if `user_token` is not specified.'
maxLength: 36
minLength: 1
type: string
created_time:
description: Date and time when the program transfer object was created, in UTC.
format: date-time
type: string
currency_code:
description: Three-digit ISO 4217 currency code.
type: string
fees:
description: Contains attributes that define characteristics of one or more fees.
items:
$ref: '#/components/schemas/fee_detail'
type: array
jit_funding:
$ref: '#/components/schemas/jit_funding_api'
memo:
description: Additional description of the program transfer.
maxLength: 99
minLength: 1
type: string
# --- truncated at 32 KB (203 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/marqeta/refs/heads/main/openapi/marqeta-cards-api-openapi.yml