Skip to main content
GET
/
sourceRules
/
{ruleId}
Get a specific source rule
curl --request GET \
  --url https://api.paygentic.io/v0/sourceRules/{ruleId} \
  --header 'Authorization: Bearer <token>'
{
  "id": "<string>",
  "sourceId": "<string>",
  "name": "<string>",
  "description": "<string>",
  "enabled": true,
  "conditions": [
    {
      "type": "date",
      "operator": "equals",
      "value": "<string>"
    }
  ],
  "order": 123,
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "createdBy": "<string>",
  "lastEvaluatedAt": "2023-11-07T05:31:56Z",
  "evaluationCount": 123,
  "matchCount": 123
}

Authorizations

Authorization
string
header
required

API key authentication

Path Parameters

ruleId
string
required

Response

Rule details

An auto-acceptance rule that automatically approves source events matching specified conditions. Rules help automate the approval process for trusted customers or specific transaction patterns.

id
string

Unique identifier for the rule

sourceId
string

ID of the source this rule belongs to

name
string

Human-readable name for the source rule

description
string

Detailed description of what this source rule does

enabled
boolean

Whether this rule is currently active

conditions
object[]

List of conditions that must ALL be met (AND logic)

order
integer

Priority order for rule evaluation (lower numbers are evaluated first)

createdAt
string<date-time>

When the rule was created

updatedAt
string<date-time>

When the rule was last updated

createdBy
string | null

User ID who created the rule

lastEvaluatedAt
string<date-time> | null

Last time this rule was evaluated against an invoice

evaluationCount
integer

Total number of times this rule has been evaluated

matchCount
integer

Number of times this rule has matched and auto-accepted an invoice