Required role: | REGISUserRole |
POST | /DynamicsCRM/Donation/Upsert |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class CRMDonationUpsertRequest
{
public Integer regent_id = null;
public Integer soft_credit_regent_id = null;
public Integer soft_credit_second_regent_id = null;
public Integer import_id = null;
public Boolean is_contact = null;
public Boolean is_account = null;
public String name = null;
public String description = null;
public BigDecimal total_pledge_amount = null;
public BigDecimal receipt_amount = null;
public String currency = null;
public String receipting_organization = null;
public String type = null;
public Date gift_date = null;
public String cheque_number = null;
public Boolean do_not_receipt = null;
public Boolean is_complete = null;
public Boolean anonymous = null;
public String gift_batch = null;
public String source = null;
public String channel = null;
public String designation = null;
public String designation_description = null;
public String campaign = null;
public String campaign_code = null;
public String campaign_description = null;
public Date campaign_start_date = null;
public Date campaign_end_date = null;
public BigDecimal campaign_goal = null;
public String appeal = null;
public String appeal_code = null;
public String appeal_description = null;
public Date appeal_start_date = null;
public Date appeal_end_date = null;
public BigDecimal appeal_goal = null;
public Date added_date = null;
public Integer getRegentId() { return regent_id; }
public CRMDonationUpsertRequest setRegentId(Integer value) { this.regent_id = value; return this; }
public Integer getSoftCreditRegentId() { return soft_credit_regent_id; }
public CRMDonationUpsertRequest setSoftCreditRegentId(Integer value) { this.soft_credit_regent_id = value; return this; }
public Integer getSoftCreditSecondRegentId() { return soft_credit_second_regent_id; }
public CRMDonationUpsertRequest setSoftCreditSecondRegentId(Integer value) { this.soft_credit_second_regent_id = value; return this; }
public Integer getImportId() { return import_id; }
public CRMDonationUpsertRequest setImportId(Integer value) { this.import_id = value; return this; }
public Boolean getIsContact() { return is_contact; }
public CRMDonationUpsertRequest setIsContact(Boolean value) { this.is_contact = value; return this; }
public Boolean getIsAccount() { return is_account; }
public CRMDonationUpsertRequest setIsAccount(Boolean value) { this.is_account = value; return this; }
public String getName() { return name; }
public CRMDonationUpsertRequest setName(String value) { this.name = value; return this; }
public String getDescription() { return description; }
public CRMDonationUpsertRequest setDescription(String value) { this.description = value; return this; }
public BigDecimal getTotalPledgeAmount() { return total_pledge_amount; }
public CRMDonationUpsertRequest setTotalPledgeAmount(BigDecimal value) { this.total_pledge_amount = value; return this; }
public BigDecimal getReceiptAmount() { return receipt_amount; }
public CRMDonationUpsertRequest setReceiptAmount(BigDecimal value) { this.receipt_amount = value; return this; }
public String getCurrency() { return currency; }
public CRMDonationUpsertRequest setCurrency(String value) { this.currency = value; return this; }
public String getReceiptingOrganization() { return receipting_organization; }
public CRMDonationUpsertRequest setReceiptingOrganization(String value) { this.receipting_organization = value; return this; }
public String getType() { return type; }
public CRMDonationUpsertRequest setType(String value) { this.type = value; return this; }
public Date getGiftDate() { return gift_date; }
public CRMDonationUpsertRequest setGiftDate(Date value) { this.gift_date = value; return this; }
public String getChequeNumber() { return cheque_number; }
public CRMDonationUpsertRequest setChequeNumber(String value) { this.cheque_number = value; return this; }
public Boolean isDoNotReceipt() { return do_not_receipt; }
public CRMDonationUpsertRequest setDoNotReceipt(Boolean value) { this.do_not_receipt = value; return this; }
public Boolean getIsComplete() { return is_complete; }
public CRMDonationUpsertRequest setIsComplete(Boolean value) { this.is_complete = value; return this; }
public Boolean isAnonymous() { return anonymous; }
public CRMDonationUpsertRequest setAnonymous(Boolean value) { this.anonymous = value; return this; }
public String getGiftBatch() { return gift_batch; }
public CRMDonationUpsertRequest setGiftBatch(String value) { this.gift_batch = value; return this; }
public String getSource() { return source; }
public CRMDonationUpsertRequest setSource(String value) { this.source = value; return this; }
public String getChannel() { return channel; }
public CRMDonationUpsertRequest setChannel(String value) { this.channel = value; return this; }
public String getDesignation() { return designation; }
public CRMDonationUpsertRequest setDesignation(String value) { this.designation = value; return this; }
public String getDesignationDescription() { return designation_description; }
public CRMDonationUpsertRequest setDesignationDescription(String value) { this.designation_description = value; return this; }
public String getCampaign() { return campaign; }
public CRMDonationUpsertRequest setCampaign(String value) { this.campaign = value; return this; }
public String getCampaignCode() { return campaign_code; }
public CRMDonationUpsertRequest setCampaignCode(String value) { this.campaign_code = value; return this; }
public String getCampaignDescription() { return campaign_description; }
public CRMDonationUpsertRequest setCampaignDescription(String value) { this.campaign_description = value; return this; }
public Date getCampaignStartDate() { return campaign_start_date; }
public CRMDonationUpsertRequest setCampaignStartDate(Date value) { this.campaign_start_date = value; return this; }
public Date getCampaignEndDate() { return campaign_end_date; }
public CRMDonationUpsertRequest setCampaignEndDate(Date value) { this.campaign_end_date = value; return this; }
public BigDecimal getCampaignGoal() { return campaign_goal; }
public CRMDonationUpsertRequest setCampaignGoal(BigDecimal value) { this.campaign_goal = value; return this; }
public String getAppeal() { return appeal; }
public CRMDonationUpsertRequest setAppeal(String value) { this.appeal = value; return this; }
public String getAppealCode() { return appeal_code; }
public CRMDonationUpsertRequest setAppealCode(String value) { this.appeal_code = value; return this; }
public String getAppealDescription() { return appeal_description; }
public CRMDonationUpsertRequest setAppealDescription(String value) { this.appeal_description = value; return this; }
public Date getAppealStartDate() { return appeal_start_date; }
public CRMDonationUpsertRequest setAppealStartDate(Date value) { this.appeal_start_date = value; return this; }
public Date getAppealEndDate() { return appeal_end_date; }
public CRMDonationUpsertRequest setAppealEndDate(Date value) { this.appeal_end_date = value; return this; }
public BigDecimal getAppealGoal() { return appeal_goal; }
public CRMDonationUpsertRequest setAppealGoal(BigDecimal value) { this.appeal_goal = value; return this; }
public Date getAddedDate() { return added_date; }
public CRMDonationUpsertRequest setAddedDate(Date value) { this.added_date = value; return this; }
}
}
Java CRMDonationUpsertRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /DynamicsCRM/Donation/Upsert HTTP/1.1
Host: data.regent-college.edu
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
regent_id: 0,
soft_credit_regent_id: 0,
soft_credit_second_regent_id: 0,
import_id: 0,
is_contact: False,
is_account: False,
name: String,
description: String,
total_pledge_amount: 0,
receipt_amount: 0,
currency: String,
receipting_organization: String,
type: String,
gift_date: 0001-01-01,
cheque_number: String,
do_not_receipt: False,
is_complete: False,
anonymous: False,
gift_batch: String,
source: String,
channel: String,
designation: String,
designation_description: String,
campaign: String,
campaign_code: String,
campaign_description: String,
campaign_start_date: 0001-01-01,
campaign_end_date: 0001-01-01,
campaign_goal: 0,
appeal: String,
appeal_code: String,
appeal_description: String,
appeal_start_date: 0001-01-01,
appeal_end_date: 0001-01-01,
appeal_goal: 0,
added_date: 0001-01-01
}
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { errorCode: String, message: String, stackTrace: String, errors: [ { errorCode: String, fieldName: String, message: String, meta: { String: String } } ], meta: { String: String } }