Skip to main content

AI-Credit Card Parser in Power Automate

AI-Credit Card Parser is a Power Automate action by PDF4me that reads a credit card image, scan, or PDF with AI and returns card number, expiry date, cardholder name, and card brand as a structured fields dictionary. Use it to automate expense tracking, card record-keeping, or reconciliation without manual data entry.

What this action does

PDF4me AI-Credit Card Parser reads a credit card document or image (PDF, PNG, JPG, or JPEG) and returns a fields dictionary that can include cardNumber, expiryDate, cardholderName, cardType, cardBrand, issuingBank, and valid-from/valid-through dates. Optionally set Body/customFieldKeys to pull additional fields beyond the standard set.

Related Blog Posts(1)

How Do I Authenticate My Power Automate Flow?

Every PDF4me action in Power Automate requires a valid connection. Create or select one that holds your PDF4me API key so the flow can authenticate AI credit card processing requests securely.

Important Facts You Should Not Miss

Only two fields are always required
File Content (the document bytes) and Body/Document/Name (the filename with extension). Body/customFieldKeys lives under Advanced parameters and is optional.
Output is a flexible fields dictionary
Extracted values sit in a fields object keyed by field name, not a fixed schema. Reference each key you need when mapping into later flow actions.
This is document extraction, not payment processing
The action reads text from a static document or image. It does not process live transactions, authorize payments, or connect to a card network.
Power Automate AI - Credit Card Parser action configured with File Content and Body/Document/Name fields

Map File Content and Body/Document/Name, then expand Advanced parameters for Body/customFieldKeys.

Parameters

Required: File Content and Body/Document/Name must always be provided. Body/customFieldKeys is an optional Advanced parameter.

ParameterRequiredWhat it doesExample
File ContentRequiredBinary content of the credit card document or image, mapped from a previous action (Get file content, SharePoint, OneDrive, email attachment). Supports .pdf, .png, .jpg, .jpeg.body('Get_file_content')
Body/Document/NameRequiredFilename of the credit card document including its extension. Used for format detection and processing.card_scan_2024.jpeg
Body/customFieldKeysOptionalAdvanced parameter. Array of additional field names to extract beyond the standard credit card data set.["customField1", "customField2"]

Output Fields

FieldTypeWhat it contains
successBooleantrue if the credit card document was processed successfully, false if extraction failed.
messageStringDescriptive message describing the result of the extraction run.
fieldsObjectDictionary of extracted credit card fields, where each key is a field name and each value holds the extracted text.
fields.bankNameStringThe name of the bank issuing the credit card, if present on the source document.
fields.cardNumberStringThe account number printed on the credit card, often partially masked in the source document.
fields.expiryDateStringThe expiration date of the credit card, typically in MM/YY format.
fields.cardholderNameStringThe name of the cardholder as it appears on the credit card.
fields.cardTypeStringThe type of credit card, for example Visa, MasterCard, or American Express.
fields.issuingBankStringThe name of the bank that issued the credit card.
fields.cardBrandStringThe brand of the credit card, for example Visa, MasterCard, or Discover.
fields.accountNumberStringThe associated bank account number, if available on the source document.
fields.validFromStringThe valid-from date of the credit card, typically in MM/YY format.
fields.validThruStringThe valid-through date of the credit card, often the same as expiryDate.
warningsArrayWarning messages indicating potential data quality issues encountered during processing.
fallbackUsedBooleantrue if fallback extraction methods were used to process the document.
jobIdStringUnique identifier for the AI processing job, used for tracking and debugging.
jobIdExtStringExternal job identifier for integration with third-party systems, if applicable.
{
"fields": {
"bankName": { "value": "Chase Bank" },
"cardNumber": { "value": "XXXX-XXXX-XXXX-1234" },
"expiryDate": { "value": "12/25" },
"cardholderName": { "value": "JOHN MICHAEL SMITH" },
"cardType": { "value": "Visa" },
"issuingBank": { "value": "Chase Bank" },
"cardBrand": { "value": "Visa" },
"accountNumber": { "value": "1234567890" },
"validFrom": { "value": "01/22" },
"validThru": { "value": "12/25" },
"customField1": { "value": "Value for Custom Field 1" }
},
"warnings": [],
"fallbackUsed": false,
"jobId": "87654321-4321-4321-4321-210987654321",
"jobIdExt": "CC-2024-001",
"success": true,
"message": "Credit card data extracted successfully using AI technology"
}

How Do I Set Up AI-Credit Card Parser in Power Automate?

  1. Add PDF4meAI-Credit Card Parser to your Power Automate flow.
  2. Map File Content from a previous action (SharePoint, OneDrive, Dropbox, or an email attachment).
  3. Set Body/Document/Name with the file's extension (.pdf, .png, .jpg, or .jpeg).
  4. Optionally expand Advanced parameters and set Body/customFieldKeys for any fields beyond the standard set.
  5. Run the flow. The parsed result returns as a fields dictionary with card, cardholder, and bank details, plus warnings and fallbackUsed flags.

Typical Setups

Workflow ExamplesCommon Power Automate flow patterns using AI-Credit Card Parser.
Expense tracking intake
  1. A flow triggers when a card statement or receipt is uploaded to SharePoint or received by email.
  2. AI-Credit Card Parser extracts cardholderName, cardBrand, and expiryDate.
  3. The extracted fields are written to a SharePoint list or expense management system.
  4. A Condition flags rows with warnings for manual review before approval.
Card record management
  1. A flow triggers when a new card document is received via email or SharePoint upload.
  2. AI-Credit Card Parser extracts cardNumber, issuingBank, and validThru.
  3. A card record is created or updated in a SharePoint list, with an expiry reminder scheduled.
Financial reconciliation
  1. A flow triggers when a card statement is uploaded to a reconciliation folder.
  2. AI-Credit Card Parser extracts accountNumber and cardholderName.
  3. Extracted fields feed an Excel or SQL reconciliation worksheet for matching against accounting records.

Practical Tips

Reference fields by key, not by fixed position
The fields dictionary is keyed by field name, so read each value with its key rather than assuming a fixed field order.
Always branch on success and warnings
Check success before writing extracted data downstream, and inspect the warnings array for any fields the parser flagged as uncertain.
Custom fields extend, they do not replace
Body/customFieldKeys adds extra entries alongside the standard fields, it does not narrow or filter the standard set.
Treat card numbers as sensitive by default
Mask or restrict access to cardNumber and accountNumber in downstream storage; this action extracts text, it does not apply its own masking.
Match the file extension to the real format
Body/Document/Name must carry the true extension (.pdf, .png, .jpg, .jpeg) of the mapped File Content, a mismatched extension can affect processing.

Cheat Sheet

FieldValue
ActionAI-Credit Card Parser
Required fieldsFile Content, Body/Document/Name
Optional advanced fieldBody/customFieldKeys
Supported file types.pdf, .png, .jpg, .jpeg
Output rootfields (dictionary)
Key output fieldscardNumber, expiryDate, cardholderName, cardType, cardBrand, issuingBank, accountNumber, validFrom, validThru, warnings, fallbackUsed

Common Questions

What data can the AI-Credit Card Parser extract from a credit card?+
Card number, expiry date, cardholder name, card type, card brand, issuing bank, and valid-from/valid-through dates, returned as a fields dictionary. The exact fields present depend on what is printed on the source image or PDF.
Does PDF4me store or process live payment transactions?+
No. This action reads a static document or image, such as a card scan, statement, or photo, and extracts text fields with AI. It does not process payments, authorize transactions, or connect to any card network. See <a href="https://www.pcisecuritystandards.org/" target="_blank" rel="noopener noreferrer">PCI Security Standards Council</a> for how payment card data handling is regulated separately from document extraction.
Can I extract fields beyond the standard credit card data set?+
Yes. Set Body/customFieldKeys to an array of additional field names under Advanced parameters. Each key you list is extracted alongside the standard fields, in addition to the built-in set.
What file formats does the AI-Credit Card Parser accept?+
PDF, PNG, JPG, and JPEG. Body/Document/Name must include the matching file extension for correct format detection and processing.
Is extracted card data automatically masked or PCI DSS certified?+
The action returns whatever text it reads from the source document; it does not apply its own masking or claim PCI DSS certification. Flow builders handling live card numbers should apply their own masking, access control, and compliance review, following guidance such as <a href="https://learn.microsoft.com/en-us/power-platform/admin/wp-data-governance" target="_blank" rel="noopener noreferrer">Microsoft's Power Platform data governance documentation</a>, before storing extracted data.

Industry Use Cases & Applications

Finance & Accounting Use Cases

  • Expense Processing: Automate expense data extraction from credit cards
  • Financial Reconciliation: Reconcile credit card transactions with accounting records
  • Expense Reporting: Generate expense reports from extracted credit card data
  • Audit Compliance: Maintain structured credit card data for audit trails
  • Budget Tracking: Track expenses using extracted credit card information

Same Task on Other Platforms

Get Help