Trendsic Platform Service

<back to all web services

EventAgentRegistrationRequest

Requires Authentication
The following routes are available for this service:
GET,PUT,DELETE,OPTIONS/v1/EventAgentRegistration/{EventRegistrationId}
import datetime
import decimal
from marshmallow.fields import *
from servicestack import *
from typing import *
from dataclasses import dataclass, field
from dataclasses_json import dataclass_json, LetterCase, Undefined, config
from enum import Enum, IntEnum


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EventRegistration:
    event_registration_id: Optional[str] = None
    description: Optional[str] = None
    summary: Optional[str] = None
    page_content: Optional[str] = None
    registration_start: datetime.datetime = datetime.datetime(1, 1, 1)
    registration_end: datetime.datetime = datetime.datetime(1, 1, 1)
    registration_count: int = 0
    active: bool = False


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EventAgentRegistration(EventRegistration):
    event_agent_registration_id: int = 0
    agent_id: int = 0
    date_created: datetime.datetime = datetime.datetime(1, 1, 1)
    is_registered: bool = False


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EventAgentRegistrationResponse:
    response_status: Optional[ResponseStatus] = None
    event_agent_registration: List[EventAgentRegistration] = field(default_factory=list)


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EventAgentRegistrationRequest:
    event_agent_registration: List[EventAgentRegistration] = field(default_factory=list)
    event_registration_id: Optional[str] = None

Python EventAgentRegistrationRequest DTOs

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

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

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

PUT /v1/EventAgentRegistration/{EventRegistrationId} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"EventAgentRegistration":[{"EventAgentRegistrationId":0,"AgentId":0,"DateCreated":"0001-01-01T00:00:00.0000000","IsRegistered":false,"EventRegistrationId":"00000000000000000000000000000000","Description":"String","Summary":"String","PageContent":"String","RegistrationStart":"0001-01-01T00:00:00.0000000","RegistrationEnd":"0001-01-01T00:00:00.0000000","RegistrationCount":0,"Active":false}],"EventRegistrationId":"00000000000000000000000000000000"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"EventAgentRegistration":[{"EventAgentRegistrationId":0,"AgentId":0,"DateCreated":"0001-01-01T00:00:00.0000000","IsRegistered":false,"EventRegistrationId":"00000000000000000000000000000000","Description":"String","Summary":"String","PageContent":"String","RegistrationStart":"0001-01-01T00:00:00.0000000","RegistrationEnd":"0001-01-01T00:00:00.0000000","RegistrationCount":0,"Active":false}]}