In general, Activities can be created, updated or retrieved using the keywords below.

Keywords

activity/get

The get keyword allows the B1WebAPI web service to retrieve an existing Activity’s object XML.

Syntax: [/<optional-profile>]/activity/get/<activity-key>.aspx

Example (default profile): /activity/get/12.aspx

Example (“myCompany” profile): /myCompany/activity/get/12.aspx

Activity/Get XML Response Sample

<Activity>
<ActivityCode>12</ActivityCode>
<CardCode>C23900</CardCode>
<Notes nil="true"/>
<ActivityDate>2016-03-29</ActivityDate>
<ActivityTime>15:14:00</ActivityTime>
<StartDate>2016-03-29</StartDate>
<Closed>tNO</Closed>
<CloseDate nil="true"/>
<Phone>555-0119</Phone>
<Fax nil="true"/>
<Subject>-1</Subject>
<DocType>-1</DocType>
<DocNum nil="true"/>
<DocEntry nil="true"/>
<Priority>pr_Normal</Priority>
<Details>test task</Details>
<Activity>cn_Task</Activity>
<ActivityType>-1</ActivityType>
<Location>-1</Location>
<StartTime>15:14:00</StartTime>
<EndTime>15:29:00</EndTime>
<Duration>15.000000</Duration>
<DurationType>du_Minuts</DurationType>
<SalesEmployee>-1</SalesEmployee>
<ContactPersonCode>3</ContactPersonCode>
<HandledBy nil="true"/>
<Reminder>tNO</Reminder>
<ReminderPeriod>15.000000</ReminderPeriod>
<ReminderType>du_Minuts</ReminderType>
<City nil="true"/>
<PersonalFlag>tNO</PersonalFlag>
<Street nil="true"/>
<ParentObjectId>3</ParentObjectId>
<ParentObjectType>97</ParentObjectType>
<Room nil="true"/>
<InactiveFlag>tNO</InactiveFlag>
<State nil="true"/>
<PreviousActivity nil="true"/>
<Country nil="true"/>
<Status>-2</Status>
<TentativeFlag>tNO</TentativeFlag>
<EndDueDate>2016-03-29</EndDueDate>
<DocTypeEx>-1</DocTypeEx>
<AttachmentEntry nil="true"/>
<RecurrencePattern>rpNone</RecurrencePattern>
<EndType>etNoEndDate</EndType>
<SeriesStartDate>2016-03-29</SeriesStartDate>
<SeriesEndDate nil="true"/>
<MaxOccurrence nil="true"/>
<Interval>1</Interval>
<Sunday>tNO</Sunday>
<Monday>tNO</Monday>
<Tuesday>tNO</Tuesday>
<Wednesday>tNO</Wednesday>
<Thursday>tNO</Thursday>
<Friday>tNO</Friday>
<Saturday>tNO</Saturday>
<RepeatOption>roByDate</RepeatOption>
<BelongedSeriesNum nil="true"/>
<IsRemoved>tNO</IsRemoved>
<AddressName nil="true"/>
<AddressType>bo_ShipTo</AddressType>
<HandledByEmployee>1</HandledByEmployee>
<RecurrenceSequenceSpecifier nil="true"/>
<RecurrenceDayInMonth nil="true"/>
<RecurrenceMonth nil="true"/>
<RecurrenceDayOfWeek nil="true"/>
<SalesOpportunityId>3</SalesOpportunityId>
<SalesOpportunityLine>1</SalesOpportunityLine>
<U_ZEDS_OPPNUM nil="true"/>
<U_ZEDS_OPPLINE nil="true"/>
</Activity>

activity/insert

The insert keyword is used to create a new Activity.

Syntax: [/<optional-profile>]/activity/insert.aspx

Example (default profile): /activity/insert.aspx

Example (“myCompany” profile): /myCompany/activity/insert.aspx

Activity XML Example

<Activity xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <ActivityCode>12</ActivityCode>
  <CardCode>C44000</CardCode>
  <ActivityDate>2016-03-24T13:08:53.9650306-02:30</ActivityDate>
  <ActivityTime xsi:nil="true" nil="true" />
  <StartDate>2016-03-24T13:08:53.9650306-02:30</StartDate>
  <CloseDate xsi:nil="true" nil="true" />
  <Details>test</Details>
  <Activity>cn_Task</Activity>
  <HandledBy>9</HandledBy>
  <EndDueDate xsi:nil="true" nil="true" />
  <SeriesStartDate xsi:nil="true" nil="true" />
  <SeriesEndDate xsi:nil="true" nil="true" />
  <SalesOpportunityId>118</SalesOpportunityId>
  <SalesOpportunityLine>157</SalesOpportunityLine>
</Activity>

activity/update

The update keyword is used to update an existing Activity.

Syntax: [/<optional-profile>]/activity/update/<activity-key>.aspx

Example (default profile): /activity/update/12.aspx

Example (“myCompany” profile): /myCompany/activity/update/12.aspx