Required role: | REGISUserRole |
POST | /DynamicsCRM/Payments |
---|
"use strict";
export class CRMPaymentResponse {
/** @param {{regent_id?:number,contact_addressee?:string,donor_first_name?:string,donor_last_name?:string,donor_addressee?:string,donor_city?:string,donor_country?:string,donor_owner_full_name?:string,is_contact?:boolean,is_account?:boolean,soft_credit_regent_id?:number,soft_credit_contact_addressee?:string,soft_credit_contact_first_name?:string,soft_credit_contact_last_name?:string,soft_credit_contact_spouse_is_main_contact?:boolean,soft_credit_contact_city?:string,soft_credit_contact_country?:string,soft_credit_contact_owner_full_name?:string,soft_credit_second_regent_id?:number,soft_credit_second_contact_addressee?:string,soft_credit_second_contact_first_name?:string,soft_credit_second_contact_last_name?:string,soft_credit_second_contact_spouse_is_main_contact?:boolean,soft_credit_second_contact_city?:string,soft_credit_second_contact_country?:string,soft_credit_second_contact_owner_full_name?:string,spouse_is_main_contact?:boolean,import_id?:number,donation_id?:string,payment_id?:string,guid?:string,name?:string,description?:string,appeal_code?:string,designation?:string,designation_description?:string,general_ledger_account_number?:string,campaign?:string,total_pledge_amount?:number,total_paid_amount?:number,amount?:number,canadian_amount?:number,payment_exchange_rate?:number,receipt_amount?:number,gift_exchange_rate?:number,total_paid_canadian_amount?:number,is_recurring?:boolean,is_complete?:boolean,is_parent_donation?:boolean,currency?:string,source?:string,channel?:string,receipting_organization?:string,type?:string,push_to_gp?:boolean,finance_entry_date?:string,finance_id?:string,acknowledgment_sent?:boolean,send_acknowledgment?:boolean,acknowledgment_template_guid?:string,parent_guid?:string,anonymous?:boolean,gift_date?:string,recurring_gift_start_date?:string,recurring_gift_end_date?:string,payment_date?:string,tax_receipt?:string,tax_receipt_date_sent?:string,cheque_number?:string,version_number?:number,added_date?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
regent_id;
/** @type {string} */
contact_addressee;
/** @type {string} */
donor_first_name;
/** @type {string} */
donor_last_name;
/** @type {string} */
donor_addressee;
/** @type {string} */
donor_city;
/** @type {string} */
donor_country;
/** @type {string} */
donor_owner_full_name;
/** @type {boolean} */
is_contact;
/** @type {boolean} */
is_account;
/** @type {?number} */
soft_credit_regent_id;
/** @type {string} */
soft_credit_contact_addressee;
/** @type {string} */
soft_credit_contact_first_name;
/** @type {string} */
soft_credit_contact_last_name;
/** @type {boolean} */
soft_credit_contact_spouse_is_main_contact;
/** @type {string} */
soft_credit_contact_city;
/** @type {string} */
soft_credit_contact_country;
/** @type {string} */
soft_credit_contact_owner_full_name;
/** @type {?number} */
soft_credit_second_regent_id;
/** @type {string} */
soft_credit_second_contact_addressee;
/** @type {string} */
soft_credit_second_contact_first_name;
/** @type {string} */
soft_credit_second_contact_last_name;
/** @type {boolean} */
soft_credit_second_contact_spouse_is_main_contact;
/** @type {string} */
soft_credit_second_contact_city;
/** @type {string} */
soft_credit_second_contact_country;
/** @type {string} */
soft_credit_second_contact_owner_full_name;
/** @type {boolean} */
spouse_is_main_contact;
/** @type {?number} */
import_id;
/** @type {string} */
donation_id;
/** @type {string} */
payment_id;
/** @type {string} */
guid;
/** @type {string} */
name;
/** @type {string} */
description;
/** @type {string} */
appeal_code;
/** @type {string} */
designation;
/** @type {string} */
designation_description;
/** @type {string} */
general_ledger_account_number;
/** @type {string} */
campaign;
/** @type {number} */
total_pledge_amount;
/** @type {number} */
total_paid_amount;
/** @type {number} */
amount;
/** @type {number} */
canadian_amount;
/** @type {number} */
payment_exchange_rate;
/** @type {number} */
receipt_amount;
/** @type {?number} */
gift_exchange_rate;
/** @type {?number} */
total_paid_canadian_amount;
/** @type {boolean} */
is_recurring;
/** @type {boolean} */
is_complete;
/** @type {boolean} */
is_parent_donation;
/** @type {string} */
currency;
/** @type {string} */
source;
/** @type {string} */
channel;
/** @type {string} */
receipting_organization;
/** @type {string} */
type;
/** @type {boolean} */
push_to_gp;
/** @type {?string} */
finance_entry_date;
/** @type {string} */
finance_id;
/** @type {boolean} */
acknowledgment_sent;
/** @type {boolean} */
send_acknowledgment;
/** @type {string} */
acknowledgment_template_guid;
/** @type {string} */
parent_guid;
/** @type {boolean} */
anonymous;
/** @type {?string} */
gift_date;
/** @type {?string} */
recurring_gift_start_date;
/** @type {?string} */
recurring_gift_end_date;
/** @type {?string} */
payment_date;
/** @type {string} */
tax_receipt;
/** @type {?string} */
tax_receipt_date_sent;
/** @type {string} */
cheque_number;
/** @type {number} */
version_number;
/** @type {?string} */
added_date;
}
export class CRMPaymentsResponse {
/** @param {{responseStatus?:ResponseStatus,payments?:CRMPaymentResponse[],from_date?:string,to_date?:string,start_version_number?:number,end_version_number?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {ResponseStatus} */
responseStatus;
/** @type {CRMPaymentResponse[]} */
payments;
/** @type {?string} */
from_date;
/** @type {?string} */
to_date;
/** @type {?number} */
start_version_number;
/** @type {?number} */
end_version_number;
}
export class CRMPaymentsRequest {
/** @param {{from_date?:string,to_date?:string,regent_id?:number,start_version_number?:number,end_version_number?:number,recurring_only?:boolean,completed_only?:boolean}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {?string} */
from_date;
/** @type {?string} */
to_date;
/** @type {?number} */
regent_id;
/** @type {?number} */
start_version_number;
/** @type {?number} */
end_version_number;
/** @type {boolean} */
recurring_only;
/** @type {boolean} */
completed_only;
}
JavaScript CRMPaymentsRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /DynamicsCRM/Payments HTTP/1.1
Host: data.regent-college.edu
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length
{"from_date":"0001-01-01T00:00:00.0000000","to_date":"0001-01-01T00:00:00.0000000","regent_id":0,"start_version_number":0,"end_version_number":0,"recurring_only":false,"completed_only":false}
HTTP/1.1 200 OK Content-Type: text/jsonl Content-Length: length {"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}},"payments":[{"regent_id":0,"contact_addressee":"String","donor_first_name":"String","donor_last_name":"String","donor_addressee":"String","donor_city":"String","donor_country":"String","donor_owner_full_name":"String","is_contact":false,"is_account":false,"soft_credit_regent_id":0,"soft_credit_contact_addressee":"String","soft_credit_contact_first_name":"String","soft_credit_contact_last_name":"String","soft_credit_contact_spouse_is_main_contact":false,"soft_credit_contact_city":"String","soft_credit_contact_country":"String","soft_credit_contact_owner_full_name":"String","soft_credit_second_regent_id":0,"soft_credit_second_contact_addressee":"String","soft_credit_second_contact_first_name":"String","soft_credit_second_contact_last_name":"String","soft_credit_second_contact_spouse_is_main_contact":false,"soft_credit_second_contact_city":"String","soft_credit_second_contact_country":"String","soft_credit_second_contact_owner_full_name":"String","spouse_is_main_contact":false,"import_id":0,"donation_id":"String","payment_id":"String","guid":"String","name":"String","description":"String","appeal_code":"String","designation":"String","designation_description":"String","general_ledger_account_number":"String","campaign":"String","total_pledge_amount":0,"total_paid_amount":0,"amount":0,"canadian_amount":0,"payment_exchange_rate":0,"receipt_amount":0,"gift_exchange_rate":0,"total_paid_canadian_amount":0,"is_recurring":false,"is_complete":false,"is_parent_donation":false,"currency":"String","source":"String","channel":"String","receipting_organization":"String","type":"String","push_to_gp":false,"finance_entry_date":"0001-01-01T00:00:00.0000000","finance_id":"String","acknowledgment_sent":false,"send_acknowledgment":false,"acknowledgment_template_guid":"String","parent_guid":"String","anonymous":false,"gift_date":"0001-01-01T00:00:00.0000000","recurring_gift_start_date":"0001-01-01T00:00:00.0000000","recurring_gift_end_date":"0001-01-01T00:00:00.0000000","payment_date":"0001-01-01T00:00:00.0000000","tax_receipt":"String","tax_receipt_date_sent":"0001-01-01T00:00:00.0000000","cheque_number":"String","version_number":0,"added_date":"0001-01-01T00:00:00.0000000"}],"from_date":"0001-01-01T00:00:00.0000000","to_date":"0001-01-01T00:00:00.0000000","start_version_number":0,"end_version_number":0}