Reference

Eventproduct

The eventproduct object

Attributes
Id: int required, autogenerated, unique
The unique identifier for this eventproduct
Allocation: int? optional
CalendarEventId: Id required
CurrencyId: Id required
Description: string optional
DisplayOrder: int required
EndDate: DateTime required
FinancialAccountId: Id optional
MaxTicketsPerAttendee: int? optional
Name: string required
Price: decimal required
Sales: int? optional read-only
StartDate: DateTime required
TaxRateId: Id optional
TicketNotes: string optional
Visible: bool optional
UniqueId: Guid required, autogenerated, unique
The globally unique identifier for this eventproduct
SystemId: string optional api-only
User defined data about this eventproduct. This property can only be seen and updated using the API.

Json Structure Example


{
  "Id": 1234567,
  "Allocation": ,
  "CalendarEventId": 12345678,
  "CurrencyId": 12345678,
  "Description": "Description",
  "DisplayOrder": ,
  "EndDate": 2020-01-01T21:03:54Z,
  "FinancialAccountId": 12345678,
  "MaxTicketsPerAttendee": ,
  "Name": "Name",
  "Price": 1.2,
  "Sales": ,
  "StartDate": 2020-01-01T21:03:54Z,
  "TaxRateId": 12345678,
  "TicketNotes": "TicketNotes",
  "Visible": false,
  "UniqueId": "d36580fe-4d93-454f-ba31-d187a9d96d52",
  "SystemId": "{ metadata: { id: 887766, processed: true } }"
}


Find a EventProduct

This endpoint allows you to GET a list of eventproducts based on one or more filter querystring parameters.

GET https://spaces.nexudus.com/api/content/eventproducts?...

πŸ”’ Requires role "EventProduct-List"

Pagination querystring parameters
Lets control how many records to return at a time and their order.
page integer optional
?page=1
size integer optional default=25
Sets the maximum number of records to return each page of results.
?size=25
orderby string optional default=DisplayOrder
Sets the property to use when ordering the results of the search.
?orderby=Id
dir 'ascending' or 'descending' optional default=SortDirection.Ascending
Sets the direction to use when ordering the records.
?sort=ascending

Search querystring parameters
Lets you search eventproduct records based on their different properties.
Id number
?Id=12345678
EventProduct_Allocation int?
?EventProduct_Allocation=...
EventProduct_CalendarEvent CalendarEvent
?EventProduct_CalendarEvent=...
EventProduct_Currency Currency
?EventProduct_Currency=...
EventProduct_Description string
?EventProduct_Description=...
EventProduct_DisplayOrder int
?EventProduct_DisplayOrder=...
EventProduct_EndDate DateTime
?EventProduct_EndDate=...
EventProduct_FinancialAccount FinancialAccount
?EventProduct_FinancialAccount=...
EventProduct_MaxTicketsPerAttendee int?
?EventProduct_MaxTicketsPerAttendee=...
EventProduct_Name string
?EventProduct_Name=...
EventProduct_Price decimal
?EventProduct_Price=...
EventProduct_Sales int?
?EventProduct_Sales=...
EventProduct_StartDate DateTime
?EventProduct_StartDate=...
EventProduct_TaxRate TaxRate
?EventProduct_TaxRate=...
EventProduct_TicketNotes string
?EventProduct_TicketNotes=...
EventProduct_Visible bool
?EventProduct_Visible=...
EventProduct_CurrencyCode string
?EventProduct_CurrencyCode=...
EventProduct_Tariffs List of Tariff
?EventProduct_Tariffs=...

Range search querystring parameters
Lets you search eventproduct records based on a range of date or numeric values.
To_EventProduct_CreatedOn date
?To_EventProduct_CreatedOn=2010-01-01T20:32
From_EventProduct_CreatedOn date
?From_EventProduct_CreatedOn=2010-01-01T20:32
To_EventProduct_UpdatedOn date
?To_EventProduct_UpdatedOn=2010-01-01T20:32
From_EventProduct_UpdatedOn date
?From_EventProduct_UpdatedOn=2010-01-01T20:32
To_EventProduct_DisplayOrder number
?To_EventProduct_DisplayOrder=0
From_EventProduct_DisplayOrder number
?From_EventProduct_DisplayOrder=10
To_EventProduct_StartDate date
?To_EventProduct_StartDate=2010-01-01T20:32
From_EventProduct_StartDate date
?From_EventProduct_StartDate=2010-01-01T20:32
To_EventProduct_EndDate date
?To_EventProduct_EndDate=2010-01-01T20:32
From_EventProduct_EndDate date
?From_EventProduct_EndDate=2010-01-01T20:32
To_EventProduct_Allocation number
?To_EventProduct_Allocation=0
From_EventProduct_Allocation number
?From_EventProduct_Allocation=10
To_EventProduct_MaxTicketsPerAttendee number
?To_EventProduct_MaxTicketsPerAttendee=0
From_EventProduct_MaxTicketsPerAttendee number
?From_EventProduct_MaxTicketsPerAttendee=10
To_EventProduct_Sales number
?To_EventProduct_Sales=0
From_EventProduct_Sales number
?From_EventProduct_Sales=10
To_EventProduct_Price number
?To_EventProduct_Price=0
From_EventProduct_Price number
?From_EventProduct_Price=10

Example request

GET https://spaces.nexudus.com/api/content/eventproducts?EventProduct_Name=...
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

Example response


{
    "Records": [{
        "Id": 1234567,
        "CalendarEvent": ,
        "Name": "Name",
        "Description": "Description",
        "TicketNotes": "TicketNotes",
        "Visible": false,
        "DisplayOrder": ,
        "StartDate": 2020-01-01T21:03:54Z,
        "EndDate": 2020-01-01T21:03:54Z,
        "Allocation": ,
        "MaxTicketsPerAttendee": ,
        "Sales": ,
        "Price": 1.2,
        "Currency": ,
        "TaxRate": ,
        "FinancialAccount": ,
        "EventProductCurrencyCode": "...",
        "CreatedOn": "2018-07-03T06:23:01Z",
        "UpdatedOn": "2020-01-01T21:57:21Z",
        "UpdatedBy": "System",
        "UniqueId": "af874973-9ef9-4ea8-842a-630a3e11cdf1",
        "SystemId": "{ metadata: { id: 887766, processed: true } }"
    }],
    "CurrentPageSize": 25,
    "CurrentPage": 1,
    "CurrentOrderField": "Id",
    "CurrentSortDirection": 1,
    "FirstItem": 1,
    "HasNextPage": true,
    "HasPreviousPage": false,
    "LastItem": 25,
    "PageNumber": 1,
    "PageSize": 25,
    "TotalItems": 60,
    "TotalPages": 3
}


Find EventProducts by IDs

Gets one or more eventproduct records based on their Id.
GET https://spaces.nexudus.com/api/content/eventproducts?EventProduct_Id=[:id1,:id2,...]

πŸ”’ Requires role "EventProduct-List"

Querystring parameters
EventProduct_Id: array requried
?EventProduct_Id=[12345678,87654651]

Example request

GET https://spaces.nexudus.com/api/content/eventproducts?EventProduct_Id=[1234567,9876541]
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

Example response


{
    "Records": [{
        "Id": 1234567,
        "CalendarEvent": ,
        "Name": "Name",
        "Description": "Description",
        "TicketNotes": "TicketNotes",
        "Visible": false,
        "DisplayOrder": ,
        "StartDate": 2020-01-01T21:03:54Z,
        "EndDate": 2020-01-01T21:03:54Z,
        "Allocation": ,
        "MaxTicketsPerAttendee": ,
        "Sales": ,
        "Price": 1.2,
        "Currency": ,
        "TaxRate": ,
        "FinancialAccount": ,
        "EventProductCurrencyCode": "...",
        "CreatedOn": "2018-07-03T06:23:01Z",
        "UpdatedOn": "2020-01-01T21:57:21Z",
        "UpdatedBy": "System",
        "UniqueId": "f410e8d5-3f72-4b30-97b3-b2c33ec59652",
        "SystemId": "{ metadata: { id: 887766, processed: true } }"
    }],
    "CurrentPageSize": 25,
    "CurrentPage": 1,
    "CurrentOrderField": "DisplayOrder",
    "CurrentSortDirection": 1,
    "FirstItem": 1,
    "HasNextPage": true,
    "HasPreviousPage": false,
    "LastItem": 1,
    "PageNumber": 1,
    "PageSize": 25,
    "TotalItems": 1,
    "TotalPages": 1
}


Get single EventProduct by Id

Gets one eventproduct record by its Id.
GET https://spaces.nexudus.com/api/content/eventproducts/:Id

πŸ”’ Requires role "EventProduct-Read"

URL parameters
Id: number requried

Example request

GET https://spaces.nexudus.com/api/content/eventproducts/1234567
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

Example response


{
  "Id": 1234567,
  "Allocation": ,
  "CalendarEventId": 12345678,
  "CurrencyId": 12345678,
  "Description": "Description",
  "DisplayOrder": ,
  "EndDate": 2020-01-01T21:03:54Z,
  "FinancialAccountId": 12345678,
  "MaxTicketsPerAttendee": ,
  "Name": "Name",
  "Price": 1.2,
  "Sales": ,
  "StartDate": 2020-01-01T21:03:54Z,
  "TaxRateId": 12345678,
  "TicketNotes": "TicketNotes",
  "Visible": false,
  "CreatedOn": "2018-07-03T06:23:01Z",
  "UpdatedOn": "2020-01-01T21:57:21Z",
  "UpdatedBy": "System",
  "UniqueId": "03f5890d-a60b-4fef-ab11-0a57c18d9df6",
  "SystemId": "{ metadata: { id: 887766, processed: true } }"
}


Create new EventProduct

Creates a new eventproduct.
POST https://spaces.nexudus.com/api/content/eventproducts

πŸ”’ Requires role "EventProduct-Create"

Body parameters
CalendarEventId: number required
Name: string required
Description: string optional
TicketNotes: string optional
Visible: bool optional
DisplayOrder: int required
StartDate: DateTime required
EndDate: DateTime required
Allocation: int? optional
MaxTicketsPerAttendee: int? optional
Price: decimal required
CurrencyId: number required
TaxRateId: number optional
FinancialAccountId: number optional

Example request

POST https://spaces.nexudus.com/api/content/eventproducts
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

{
    "CalendarEventId": 12345678,
    "Name": "Name",
    "Description": "Description",
    "TicketNotes": "TicketNotes",
    "Visible": false,
    "DisplayOrder": ,
    "StartDate": 2020-01-01T21:03:54Z,
    "EndDate": 2020-01-01T21:03:54Z,
    "Allocation": ,
    "MaxTicketsPerAttendee": ,
    "Price": 1.2,
    "CurrencyId": 12345678,
    "TaxRateId": 12345678,
    "FinancialAccountId": 12345678,
    "Tariffs": [12345678, 87654321],
}


Example valid response


{
    "Status": 200,
    "WasSuccessful": true,
    "Message": "Record 'Name of the record' has been succesfully created.",
    "Value": {
        "Id": 12354678
    }
}


Example invalid response


{
    "Status": 500,
    "Message": "Name: may not be null or empty",
    "Value": null,
    "WasSuccessful": false,
    "Errors": [
        {
            "AttemptedValue": null,
            "Message": "may not be null or empty",
            "PropertyName": "Name"
        },
    ]
}


Update EventProduct

Updates an existing eventproduct.
PUT https://spaces.nexudus.com/api/content/eventproducts

PUT requests require ALL record properties to be submitted with every request. Any missing properties will be cleared or set to false.

πŸ”’ Requires role "EventProduct-Edit"

Body parameters
Id: number required
The unique Id of the eventproduct to update.
CalendarEventId: number cleared if missing
Name: string cleared if missing
Description: string cleared if missing
TicketNotes: string cleared if missing
Visible: bool cleared if missing
DisplayOrder: int cleared if missing
StartDate: DateTime cleared if missing
EndDate: DateTime cleared if missing
Allocation: int? cleared if missing
MaxTicketsPerAttendee: int? cleared if missing
Price: decimal cleared if missing
CurrencyId: number cleared if missing
TaxRateId: number cleared if missing
FinancialAccountId: number cleared if missing

Example request

PUT https://spaces.nexudus.com/api/content/eventproducts
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

{
    "Id": 12345678,
    "CalendarEventId": 12345678,
    "Name": "Name",
    "Description": "Description",
    "TicketNotes": "TicketNotes",
    "Visible": false,
    "DisplayOrder": ,
    "StartDate": 2020-01-01T21:03:54Z,
    "EndDate": 2020-01-01T21:03:54Z,
    "Allocation": ,
    "MaxTicketsPerAttendee": ,
    "Price": 1.2,
    "CurrencyId": 12345678,
    "TaxRateId": 12345678,
    "FinancialAccountId": 12345678,
    "Tariffs": [12345678, 87654321],
}


Example valid response


{
    "Status": 200,
    "WasSuccessful": true,
    "Message": "Record 'Name of the record' has been succesfully updated.",
    "Value": {
        "Id": 12354678
    }
}


Example invalid response


{
    "Status": 500,
    "Message": "Name: may not be null or empty",
    "Value": null,
    "WasSuccessful": false,
    "Errors": [
        {
            "AttemptedValue": null,
            "Message": "may not be null or empty",
            "PropertyName": "Name"
        },
    ]
}


Delete EventProduct

Deletes an existing eventproduct by its Id.
DELETE https://spaces.nexudus.com/api/content/eventproducts/:Id

πŸ”’ Requires role "EventProduct-Delete"

URL parameters
Id: number required
The unique Id of the eventproduct to update.

Example request

DELETE https://spaces.nexudus.com/api/content/eventproducts/12345678
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

Example valid response


{
    "Status": 200,
    "WasSuccessful": true,
    "Message": "The record was deleted successfully.",
    "Value": null,
    "OpenInDialog": false,
    "RedirectURL": null,
    "JavaScript": null,
    "Errors": null
}


Commands

Commands allow to perform actions against one or more eventproduct records. Some commands accept only one record while others can run an action for a number of records at the same time. Each command has metadata with information about how it can be used and the amount of records, if any, it needs to run.

Get Commands

Get all commands available to run for eventproduct records.
GET https://spaces.nexudus.com/api/content/eventproducts/commands

Example request

GET https://spaces.nexudus.com/api/content/eventproducts/commands
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

Example valid response


[
	{
		"Key": "COMMAND_KEY_1",
		"Name": "Command 1 english description",
		"AppliesOnlyToMultipleEntities": false,
		"DisplayInDropdown": true,
		"DisplayInDropdownV2": true,
		"AppliesOnlyToOneEntity": false,
		"AppliesOnlyToTwoEntities": false,
		"DisplayInGrid": false,
		"NeedsEntitiesToRun": true,
		"Order": 2,
		"RequiresParameters": []
	},
	{
		"Key": "COMMAND_KEY_2",
		"Name": "Command 2 english description",
		"AppliesOnlyToMultipleEntities": false,
		"DisplayInDropdown": true,
		"DisplayInDropdownV2": true,
		"AppliesOnlyToOneEntity": true,
		"AppliesOnlyToTwoEntities": false,
		"DisplayInGrid": true,
		"NeedsEntitiesToRun": true,
		"Order": 10,
		"RequiresParameters": 
		[
			{
				"Name": "Parameter 1 description",
				"Type": "string",
			},
			{
				"Name": "Parameter 2 description",
				"Type": "Boolean",
			}
		]
	},
	...
]


Run Command

Runs a command based on its Key and one or more eventproduct record IDs.
POST https://spaces.nexudus.com/api/content/eventproducts/runacommand
πŸ”’ Requires role "EventProduct-Edit"

Example request

POST https://spaces.nexudus.com/api/content/eventproducts/runcommand
Content-Type: application/json
Authentication: Basic ZXhhbXBsZUBuZXh1ZHVzLmNvbTpFeGFtcGxlMTIzNA==

{
	"Ids":[1329961649],
	"Parameters": 
	[
		{ 
			"Type": "string"
			"Value":987654321
		},
		{
			"Type": "Boolean",
			"Value":true
		},
		...
	],
	"Key":"COMMAND_KEY_2"
}


Example valid response


{
	"Errors": null
	"JavaScript": null
	"Message": "Result description"
	"OpenInDialog": false
	"OpenInWindow": false
	"RedirectURL": null
	"Status": 200
	"UpdatedBy": "email@example.net"
	"UpdatedOn: "2020-06-04T11:40:20Z"
	"Value: {Id: 12345678}
	"WasSuccessful: true
}


Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Please sign in to leave a comment.