Skip to main content
PATCH
/
api
/
preapprovedtransactions
/
{id}
/
approve-reject
Approve or reject a QuickScan transaction
curl --request PATCH \
  --url http://localhost/api/api/preapprovedtransactions/{id}/approve-reject \
  --header 'Content-Type: application/json' \
  --cookie sessionid= \
  --data '
{
  "client_transaction_id": "<string>",
  "transaction_timestamp": "2023-11-07T05:31:56Z",
  "transaction_type": "<string>",
  "amount": 123,
  "transaction_currency": "<string>",
  "payment_mode": "<string>",
  "approved_on": "2023-11-07T05:31:56Z",
  "approved_by": 123,
  "assignee": 123,
  "comment": "<string>"
}
'
import requests

url = "http://localhost/api/api/preapprovedtransactions/{id}/approve-reject"

payload = {
"client_transaction_id": "<string>",
"transaction_timestamp": "2023-11-07T05:31:56Z",
"transaction_type": "<string>",
"amount": 123,
"transaction_currency": "<string>",
"payment_mode": "<string>",
"approved_on": "2023-11-07T05:31:56Z",
"approved_by": 123,
"assignee": 123,
"comment": "<string>"
}
headers = {
"cookie": "sessionid=",
"Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'PATCH',
headers: {cookie: 'sessionid=', 'Content-Type': 'application/json'},
body: JSON.stringify({
client_transaction_id: '<string>',
transaction_timestamp: '2023-11-07T05:31:56Z',
transaction_type: '<string>',
amount: 123,
transaction_currency: '<string>',
payment_mode: '<string>',
approved_on: '2023-11-07T05:31:56Z',
approved_by: 123,
assignee: 123,
comment: '<string>'
})
};

fetch('http://localhost/api/api/preapprovedtransactions/{id}/approve-reject', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/api/preapprovedtransactions/{id}/approve-reject",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'client_transaction_id' => '<string>',
'transaction_timestamp' => '2023-11-07T05:31:56Z',
'transaction_type' => '<string>',
'amount' => 123,
'transaction_currency' => '<string>',
'payment_mode' => '<string>',
'approved_on' => '2023-11-07T05:31:56Z',
'approved_by' => 123,
'assignee' => 123,
'comment' => '<string>'
]),
CURLOPT_COOKIE => "sessionid=",
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "http://localhost/api/api/preapprovedtransactions/{id}/approve-reject"

payload := strings.NewReader("{\n \"client_transaction_id\": \"<string>\",\n \"transaction_timestamp\": \"2023-11-07T05:31:56Z\",\n \"transaction_type\": \"<string>\",\n \"amount\": 123,\n \"transaction_currency\": \"<string>\",\n \"payment_mode\": \"<string>\",\n \"approved_on\": \"2023-11-07T05:31:56Z\",\n \"approved_by\": 123,\n \"assignee\": 123,\n \"comment\": \"<string>\"\n}")

req, _ := http.NewRequest("PATCH", url, payload)

req.Header.Add("cookie", "sessionid=")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.patch("http://localhost/api/api/preapprovedtransactions/{id}/approve-reject")
.header("cookie", "sessionid=")
.header("Content-Type", "application/json")
.body("{\n \"client_transaction_id\": \"<string>\",\n \"transaction_timestamp\": \"2023-11-07T05:31:56Z\",\n \"transaction_type\": \"<string>\",\n \"amount\": 123,\n \"transaction_currency\": \"<string>\",\n \"payment_mode\": \"<string>\",\n \"approved_on\": \"2023-11-07T05:31:56Z\",\n \"approved_by\": 123,\n \"assignee\": 123,\n \"comment\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("http://localhost/api/api/preapprovedtransactions/{id}/approve-reject")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Patch.new(url)
request["cookie"] = 'sessionid='
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_transaction_id\": \"<string>\",\n \"transaction_timestamp\": \"2023-11-07T05:31:56Z\",\n \"transaction_type\": \"<string>\",\n \"amount\": 123,\n \"transaction_currency\": \"<string>\",\n \"payment_mode\": \"<string>\",\n \"approved_on\": \"2023-11-07T05:31:56Z\",\n \"approved_by\": 123,\n \"assignee\": 123,\n \"comment\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": 123,
  "client_transaction_id": "<string>",
  "cp_a": {
    "client_subject_id": "<string>",
    "subject_name": "<string>"
  },
  "cp_b": {
    "client_subject_id": "<string>",
    "subject_name": "<string>"
  },
  "name_screen_cpa": "<string>",
  "name_screen_cpb": "<string>",
  "has_related_case": "<string>",
  "related_cases": "<string>",
  "has_true_hit_cpa": "<string>",
  "has_true_hit_cpb": "<string>",
  "has_unmarked_hit_cpa": "<string>",
  "has_unmarked_hit_cpb": "<string>",
  "created_on": "2023-11-07T05:31:56Z",
  "modified_on": "2023-11-07T05:31:56Z",
  "transaction_timestamp": "2023-11-07T05:31:56Z",
  "transaction_type": "<string>",
  "amount": 123,
  "transaction_currency": "<string>",
  "payment_mode": "<string>",
  "approved_on": "2023-11-07T05:31:56Z",
  "approved_by": 123,
  "assignee": 123,
  "comment": "<string>"
}
You will need to mark all hits in the pre-approved transaction before you are able to approve or reject it.
Once all screening hits have been reviewed and marked, use this endpoint to approve or reject the pre-approved transaction. Status Options:
  • approved — Approve the transaction
  • rejected — Reject the transaction

Authorizations

sessionid
string
cookie
required

Path Parameters

id
integer
required

A unique integer value identifying this pre approved transaction.

Body

Serializer for PreApprovedTransaction model.

NOTE: name_screen_cpa and name_screen_cpb are now queried dynamically via client_transaction_id (no longer FK fields). Maintains backward compatibility.

client_transaction_id
string

Client's transaction ID (unique identifier)

Required string length: 1 - 255
status
enum<string>

Status of the pre-approval workflow

  • on_hold - on_hold
  • approved - approved
  • rejected - rejected
  • not_screened - not_screened
  • cleared - cleared
Available options:
on_hold,
approved,
rejected,
not_screened,
cleared
transaction_timestamp
string<date-time> | null
transaction_type
string
Maximum string length: 255
amount
number<double> | null
transaction_currency
string | null

Transaction currency code

Minimum string length: 1
payment_mode
string
Maximum string length: 255
approved_on
string<date-time> | null
approved_by
integer | null
assignee
integer | null

User assigned to review this transaction

comment
string

Review comment or decision rationale

Response

200 - application/json

Serializer for PreApprovedTransaction model.

NOTE: name_screen_cpa and name_screen_cpb are now queried dynamically via client_transaction_id (no longer FK fields). Maintains backward compatibility.

id
integer
required
read-only
client_transaction_id
string
required

Client's transaction ID (unique identifier)

Maximum string length: 255
cp_a
object
required
cp_b
object
required
name_screen_cpa
string
required
read-only
name_screen_cpb
string
required
read-only
has_true_hit_cpa
string
required
read-only
has_true_hit_cpb
string
required
read-only
has_unmarked_hit_cpa
string
required
read-only
has_unmarked_hit_cpb
string
required
read-only
created_on
string<date-time>
required
read-only
modified_on
string<date-time>
required
read-only
status
enum<string>

Status of the pre-approval workflow

  • on_hold - on_hold
  • approved - approved
  • rejected - rejected
  • not_screened - not_screened
  • cleared - cleared
Available options:
on_hold,
approved,
rejected,
not_screened,
cleared
transaction_timestamp
string<date-time> | null
transaction_type
string
Maximum string length: 255
amount
number<double> | null
transaction_currency
string | null

Transaction currency code

payment_mode
string
Maximum string length: 255
approved_on
string<date-time> | null
approved_by
integer | null
assignee
integer | null

User assigned to review this transaction

comment
string

Review comment or decision rationale