YM REST Services

<back to all web services

Donations

Requires Authentication
Requires any of the roles:admin, oauthadminRequires the permission:/admin/donations/
The following routes are available for this service:
POST/Ams/{ClientID}/DonationsCreate a donation invoice.
Donations Parameters:
NameParameterData TypeRequiredDescription
fundIdbodyintNo
descriptionbodystringNo
invoicebodyInvoiceNo
quickCreatingbodyboolNo
BaseDto Parameters:
NameParameterData TypeRequiredDescription
UsingRedisformboolNo
AppInitTimeformDateTimeNo
ServerIDformstringNo
BaseSharedDto Parameters:
NameParameterData TypeRequiredDescription
ClientIDformintNo
ResponseStatusformResponseStatusNo
BypassCacheformboolNo
DateCachedformDateTimeNo
DeviceformDeviceNo
Invoice Parameters:
NameParameterData TypeRequiredDescription
dateformDateTimeNo
shippingMethodIdformintNo
shippingMethodNameformstringNo
shippingTaxformdoubleNo
shippingTotalformdoubleNo
taxRateformdoubleNo
taxTotalformdoubleNo
totalAmountformdoubleNo
commentformstringNo
personformPersonNo
shippingAddressformAddressNo
invoiceItemsformList<InvoiceItem>No
isNewMemberformboolNo
taxGLCodeformstringNo
taxQBClassformstringNo
shippingGLCodeformstringNo
shippingQBClassformstringNo
Person Parameters:
NameParameterData TypeRequiredDescription
idformintNo
organizationformstringNo
firstNameformstringNo
lastNameformstringNo
middleNameformstringNo
nameSuffixformstringNo
emailAddressformstringNo
primaryAddressformAddressNo
usernameformstringNo
passwordformstringNo
isMemberformboolNo
expirationDateformstringNo
currentMembershipAllowsMultipleOpenInvoicesformboolNo
currentMembershipInvoiceIsOpenformboolNo
currentMembershipInvoiceAwaitingAutoBillformboolNo
Address Parameters:
NameParameterData TypeRequiredDescription
firstNameformstringNo
lastNameformstringNo
organizationformstringNo
address1formstringNo
address2formstringNo
cityformstringNo
locationformstringNo
postalCodeformstringNo
countryCodeformstringNo
countryNameformstringNo
areaCodeformstringNo
phoneformstringNo
InvoiceItem Parameters:
NameParameterData TypeRequiredDescription
itemTypeIdformstringNo
idformintNo
shippingCostformdoubleNo
descriptionformstringNo
customDescriptionformstringNo
taxRateformdoubleNo
taxGLCodeformstringNo
quantityformdoubleNo
amountformdoubleNo
isProRatedformboolNo
GLCodeformstringNo
isModifierformboolNo
isDuesRuleformboolNo
taxQBClassformstringNo
QBClassformstringNo
skuformstringNo
taxableformboolNo
autoPromoCodeAmountformdoubleNo
autoPromoCodeTitleformstringNo
salesDiscountformdoubleNo
AutoPromoCodeformAutoPromoCodeNo
AutoPromoCode Parameters:
NameParameterData TypeRequiredDescription
IdformintNo
TitleformstringNo
IsPercentformboolNo
DiscountformdoubleNo
DonationsResponse Parameters:
NameParameterData TypeRequiredDescription
donationIdformintNo
invoiceIdformintNo
invoiceGuidformstringNo

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /Ams/{ClientID}/Donations HTTP/1.1 
Host: ws.yourmembership.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	fundId: 0,
	description: String,
	invoice: 
	{
		date: 0001-01-01,
		shippingMethodId: 0,
		shippingMethodName: String,
		shippingTax: 0,
		shippingTotal: 0,
		taxRate: 0,
		taxTotal: 0,
		totalAmount: 0,
		comment: String,
		person: 
		{
			id: 0,
			organization: String,
			firstName: String,
			lastName: String,
			middleName: String,
			nameSuffix: String,
			emailAddress: String,
			primaryAddress: 
			{
				firstName: String,
				lastName: String,
				organization: String,
				address1: String,
				address2: String,
				city: String,
				location: String,
				postalCode: String,
				countryCode: String,
				countryName: String,
				areaCode: String,
				phone: String
			},
			username: String,
			password: String,
			isMember: False,
			expirationDate: String,
			currentMembershipAllowsMultipleOpenInvoices: False,
			currentMembershipInvoiceIsOpen: False,
			currentMembershipInvoiceAwaitingAutoBill: False,
			UsingRedis: True,
			AppInitTime: 2025-01-15T06:15:49.6223497-05:00,
			ServerID: WS-4-190-907,
			ClientID: 0,
			ResponseStatus: 
			{
				ErrorCode: String,
				Message: String,
				StackTrace: String,
				Errors: 
				[
					{
						ErrorCode: String,
						FieldName: String,
						Message: String,
						Meta: 
						{
							String: String
						}
					}
				],
				Meta: 
				{
					String: String
				}
			},
			BypassCache: False,
			DateCached: 2025-01-15T08:58:00.4243144-05:00,
			Device: Desktop
		},
		shippingAddress: 
		{
			firstName: String,
			lastName: String,
			organization: String,
			address1: String,
			address2: String,
			city: String,
			location: String,
			postalCode: String,
			countryCode: String,
			countryName: String,
			areaCode: String,
			phone: String
		},
		invoiceItems: 
		[
			{
				itemTypeId: String,
				id: 0,
				shippingCost: 0,
				description: String,
				customDescription: String,
				taxRate: 0,
				taxGLCode: String,
				quantity: 0,
				amount: 0,
				isProRated: False,
				GLCode: String,
				isModifier: False,
				isDuesRule: False,
				taxQBClass: String,
				QBClass: String,
				sku: String,
				taxable: False,
				autoPromoCodeAmount: 0,
				autoPromoCodeTitle: String,
				salesDiscount: 0,
				AutoPromoCode: 
				{
					Id: 0,
					Title: String,
					IsPercent: False,
					Discount: 0
				}
			}
		],
		isNewMember: False,
		taxGLCode: String,
		taxQBClass: String,
		shippingGLCode: String,
		shippingQBClass: String
	},
	quickCreating: False,
	UsingRedis: True,
	AppInitTime: 2025-01-15T06:15:49.6223497-05:00,
	ServerID: WS-4-190-907,
	ClientID: 0,
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	BypassCache: False,
	DateCached: 2025-01-15T08:58:00.4399832-05:00,
	Device: Desktop
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	donationId: 0,
	invoiceId: 0,
	invoiceGuid: String,
	fundId: 0,
	description: String,
	invoice: 
	{
		date: 0001-01-01,
		shippingMethodId: 0,
		shippingMethodName: String,
		shippingTax: 0,
		shippingTotal: 0,
		taxRate: 0,
		taxTotal: 0,
		totalAmount: 0,
		comment: String,
		person: 
		{
			id: 0,
			organization: String,
			firstName: String,
			lastName: String,
			middleName: String,
			nameSuffix: String,
			emailAddress: String,
			primaryAddress: 
			{
				firstName: String,
				lastName: String,
				organization: String,
				address1: String,
				address2: String,
				city: String,
				location: String,
				postalCode: String,
				countryCode: String,
				countryName: String,
				areaCode: String,
				phone: String
			},
			username: String,
			password: String,
			isMember: False,
			expirationDate: String,
			currentMembershipAllowsMultipleOpenInvoices: False,
			currentMembershipInvoiceIsOpen: False,
			currentMembershipInvoiceAwaitingAutoBill: False,
			UsingRedis: True,
			AppInitTime: 2025-01-15T06:15:49.6223497-05:00,
			ServerID: WS-4-190-907,
			ClientID: 0,
			ResponseStatus: 
			{
				ErrorCode: String,
				Message: String,
				StackTrace: String,
				Errors: 
				[
					{
						ErrorCode: String,
						FieldName: String,
						Message: String,
						Meta: 
						{
							String: String
						}
					}
				],
				Meta: 
				{
					String: String
				}
			},
			BypassCache: False,
			DateCached: 2025-01-15T08:58:00.4399832-05:00,
			Device: Desktop
		},
		shippingAddress: 
		{
			firstName: String,
			lastName: String,
			organization: String,
			address1: String,
			address2: String,
			city: String,
			location: String,
			postalCode: String,
			countryCode: String,
			countryName: String,
			areaCode: String,
			phone: String
		},
		invoiceItems: 
		[
			{
				itemTypeId: String,
				id: 0,
				shippingCost: 0,
				description: String,
				customDescription: String,
				taxRate: 0,
				taxGLCode: String,
				quantity: 0,
				amount: 0,
				isProRated: False,
				GLCode: String,
				isModifier: False,
				isDuesRule: False,
				taxQBClass: String,
				QBClass: String,
				sku: String,
				taxable: False,
				autoPromoCodeAmount: 0,
				autoPromoCodeTitle: String,
				salesDiscount: 0,
				AutoPromoCode: 
				{
					Id: 0,
					Title: String,
					IsPercent: False,
					Discount: 0
				}
			}
		],
		isNewMember: False,
		taxGLCode: String,
		taxQBClass: String,
		shippingGLCode: String,
		shippingQBClass: String
	},
	quickCreating: False,
	UsingRedis: True,
	AppInitTime: 2025-01-15T06:15:49.6223497-05:00,
	ServerID: WS-4-190-907,
	ClientID: 0,
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	BypassCache: False,
	DateCached: 2025-01-15T08:58:00.4399832-05:00,
	Device: Desktop
}