Introduction

OfficeClip Web Services
Introduction

OfficeClip Web Services allows you to interact with the OfficeClip server using a publised api. This document discusses various features of the OfficeClip api and shows example of how it can be used in real-life situation.

What is Web Services?

A web service is a piece of software that makes itself available on a web-based medium (internet or intranet) using a standardized XML messaging system. The interested party can locate the service and its public interfaces using a discovery mechanism using UDDI (Universal Description, Discovery, and Integration). Web services are easy to access via many platforms because of the standarized natture of communication. more information on web services can be found at Wikipedia.

To use a web service, the client usually creates a proxy to the web service. From there on all calls to the web service is made via proxy (as if it is made locally).

OfficeClip Web Services

OfficeClip web services models every entity (e.g. contacts, templates etc.) as a table. It offers methods to read, write, append and delete from the table. The consumer of the OfficeClip web services is isolated from the internal details of how the data is exchanged between OfficeClip database and its various layers.

OfficeClip web services identifies each OfficeClip data element using a unique identifier called sid (serial id). The sid concept is similar to the guid (globally unique identifier) as used in may platforms. The sid is unique across any OfficeClip installation and is created using the OfficeClip installation serial number, the entity and the primary key of that element in the OfficeClip database. The sid is a string that is used to communicate between the web service client and the server.

Each OfficeClip entity is identified by a "service type" for the OfficeClip web services. OfficeClip is an integrated platform of many web-based applications and it has many entities (and service types). The service types are identified by integer and is used is almost all methods in the web services interface. Some service types are divided into sub types called "service sub types". The service sub types are also represented as integer. Not all operations are valid for all service types. The valid operations are specified with the help page of the OfficeClip web services. An exception is thrown if an invalid operation is attempted on a service type.

Send comments on this topic to ocsupport@officeclip.com

Copyright OfficeClip LLC 2009


Service Items

Service Items

Following are the various service types, service sub types of the OfficClip web services. Note that the service type and sub type are always specified as integer when using it in the web service. The integral values are given in parenthesis with each service type/sub type.

Service Type (Id) | Service Sub Type (Id) | Description
Task(8) ContactManager(15),
Account(31) 		The OfficeClip Task. If the Service SubType is specified it will only get the data related to the SubType. This value should be empty on update and insert.
Member(11) | The OfficeClip Member (User).
Organization(13) | The OfficeClip Organization.
Event(14) ContactManager(15),
Account(31) 		The OfficeClip Calendar Event. If the Service SubType is specified it will only get the data related to the SubType. This value should be empty on update and insert.
Contact(18) | The contact management metaentity.
Note(20) ContactManager(15),
Account(31) 		The OfficeClip Notes. If the Service SubType is specified it will only get the data related to the SubType. This value should be empty on update and insert.
Template Parent Child(23) | ContactManager(15) | The parent child values of the template. The service sub type for this type is the template type.
Attachment(24) | Document attachments with various applications.
Return Value(25) | The return value format for various operations (e.g. Insert, Update). It consists of error number and error description.
Template Key Value(27) | The Template key value information (used to merge a template).
Mail Merge Campaign(28) | The mail merge campaign information. This consists of campaign name, description, created date etc.
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information. It consists of campaign sid and contact sid.
System Information(30) | Provides the current organization and other system information.
Account(31) | The Account information, accounts are customers of the company.
Project(32) | The project information that is attached to timesheet and expenses
Service Item(33) | The Service items are the tasks that is used in the timesheet
Timesheet(34) | Represents a single timesheet, each timesheets can have multiple timesheet detail entries
Timesheet Detail(35) | Represents an unit of work in the timesheet
Expense(36) | Represents a single expense, each expenses can have multiple expense detail entries
Expense Detail(37) | Represents an unit of work in the expense
Expense Type(38) | Various expense types
Meta Information(39) | ContactManager(18), Account(31) | The attribute information for meta entities like Contact, Account, Opportunity etc.
Payroll Categories(40) | The payroll categories.


Application Ids

Application Ids

Following are the application ids that are used by OfficeClip. Some web services calls require the application id to operate correctly

Id | Application Name
1 | Calendar
3 | GroupBookmark
5 | Tracker
7 | Expense Report
8 | Timesheet
9 | Bulletin Board
10 | Document Management
13 | Members
14 | Home Page
15 | Alerts
16 | Polls
18 | Announcements
19 | Email
20 | Tasks
21 | Notes
22 | Contact Manager
23 | Extranet
24 | Account Manager
25 | Newsfeed
26 | Address Book
27 | Campaigns
28 | Opportunities
29 | Projects


Account

Schema: Account

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
accountId | int | The unique id of the account in the OfficeClip database
accountNumber | string | The account number of the account, it is advised that this needs to be unique
orgId | int | The unique id of the organization in the OfficeClip database where the contact belongs
accountName | string | The name of the account
shortName | string | The short name of the account
parentAccountSid | string | The sid of the parent account
primaryContact | string | The name of the primary contact
relationshipType | string | The relationType for the account
webSite | string | The website for the account
emailAddress | string | The email address of the account
mainPhone | string | The primary phone number for the account
otherPhone | string | The other phone number for the account
fax | string | The fax number of the account
isArchive | boolean | Shows if the account is archived
address1 | string | The first address line for the account
address2 | string | The second address line for the account
city | string | The city of the account address
state | string | The state of the account address
zip | string | The zip code of the account address
country | string | The country of the account address
description | string | The description of the account
createdUser | string | The name of the user that created the account
createdDate | dateTime | The created date for the account
owner | string | The name of the user who is assigned the current account
modifiedUser | string | The name of the user that modified the account
modifiedDate | dateTime | The modified date for the account
currency | string | The currency of the account
industry | string | The industry of the account
annualRevenue | double | The annual revenue of the account
numEmployees | int | The number of employees
sicCode | string | The sic code for the account
ownership | string | The ownership for the account
tickerSymbol | string | The ticker symbol for the account
accountSource | string | The account source
udf1 | string | The first user defined field
udf2 | string | The second user defined field
udf3 | string | The third user defined field
udf4 | string | The fourth user defined field
udf5 | string | The fifth user defined field
udf6 | string | The sixth user defined field
udf7 | string | The seventh user defined field
udf8 | string | The eighth user defined field
udf9 | string | The nineth user defined field
udf10 | string | The tenth user defined field


Attachment

Schema: Attachment

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
fileName | string | The name of the attachment file
documentKey | string | The document key that can be used to search the attachment
documentDescription | string | The document description for the attachment
applicationId | int | The unique application id in OfficeClip
applicationSecondaryId | int | The unique application secondary id in OfficeClip, in case there are attachments for multiple entites in the application
id | string | The id of the entity to which this attachment is connected
isZipped | boolean | If the attachment is supplied compressed (currently not implemented)
bytes | base64Binary | The base64 binary byte for the attachment


Contact

Schema: Contact

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
contactId | int | The unique id of the contact in the OfficeClip database
orgId | int | The unique id of the organization in the OfficeClip database where the contact belongs
firstName | string | The first name of the contact
lastName | string | The last name of the contact
salutation | string | The salutation of the contact
title | string | The title of the contact
companyName | string | The company name of the contact
workPhone | string | The work phone number for the contact
department | string | The detaprtment where the contact works
reportsTo | string | The name of the person or position who this contact reports to
emailAddress | string | The email address for the contact
emailOptOut | boolean | Shows whether the contact has desired to be opted out from the email
mobilePhone | string | The mobile phone number of the contact
alternateWorkPhone | string | The alternate work phone number for the contact
fax | string | The fax number of the contact
homePhone | string | The home phone number for the contact
currencyType | string | The currency type for the contact e.g. dollars, pounds etc.
birthDate | dateTime | The birth date for the contact
assistantName | string | The name of the assistant of the contact
assistantPhone | string | The phone number of the assistant of the contact
address1 | string | The first line of the primary street address of the contact
otherAddress1 | string | The first line of the other street address of the contact
address2 | string | The second line of the primary street address of the contact
otherAddress2 | string | The second line of the other street address of the contact
city | string | the primary city of the contact
otherCity | string | The other city of the contact
state | string | The primary state of the contact
otherState | string | The other state of the contact
zip | string | The primary zip code for the contact
otherZip | string | The other zip code for the contact
country | string | The primary country for the contact
otherCountry | string | The other country for the contact
contactSource | string | The source of the contact e.g. trade shows, cafe etc.
description | string | The description for the contact
createdUser | string | The name of the user that created the contact
createdDate | dateTime | The created date for the contact
modifiedUser | string | The name of the user that modified the contact
modifiedDate | dateTime | The modified date for the contact
owner | string | The name of the user who is assigned the current contact
udf1 | string | The first user defined field
udf2 | string | The second user defined field
udf3 | string | The third user defined field
udf4 | string | The fourth user defined field
udf5 | string | The fifth user defined field
udf6 | string | The sixth user defined field
udf7 | string | The seventh user defined field
udf8 | string | The eighth user defined field
udf9 | string | The nineth user defined field
udf10 | string | The tenth user defined field


Event

Schema: Event

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
eventId | int | The unique id of the event in the OfficeClip database
eventType | int | The event type, valid types are None = -1, Organization Event (visible to the entire organization) = 1, Meeting(visible only to attendees) = 2, Personal Event(visible only to the creator) = 3
eventName | string | The name of the event
eventDescription | string | Detailed description of the event
startDateTime | dateTime | The date time when the event starts
endDateTime | dateTime | The date time when the event ends
isAllDayEvent | boolean | Shows if the event is an all day event. If so, the start time and end time is ignored
eventUserSid | string | The Sid of the user who created the event
eventLocation | string | The location of the event
repeatTextInfo | string | The text of the repeat information if the event repeats
isRSVP | boolean | Shows if RSVP is requested for the event. Valid only for organization events
showAs | int | How the event will be shown as in the cretor calendar. Valid values are Busy = 0, Free = 1, Out of Office = 2, Tentative = 3
createdByUserSid | string | The sid of the user who created the event
createdByUserName | string | The name of the user who created the event
createdByTimestamp | dateTime | The timestamp of the user who created the event
meetingAttendees | string | A comma separated list of attendees in the format name1(emailAddress1), name2(emailAddress2)... etc. Valid only for the meeting type events
timeZoneId | int | The internal timezone id of the event
isReminderSelected | boolean | Shows if the reminder is selected for the event
whoToRemind | string | The string representation of who needs to be reminded
remindAtDateTime | dateTime | The date and time when the reminder should occur
url | string | The url of the event (if any)
resourceId | int | The internal id of the resource for this event
resourceName | string | The name of the resource
isReserved | boolean | The status of the resource reservation
modifiedByUserName | string | The name of the user who modified the event
modifiedByUserSid | string | The sid of the user who last modified the event
modifiedByTimestamp | dateTime | The timestamp of the user who last modified the event
parentObjectServiceType | int | The service type of the parent object, -1 if not parent object exist
parentObjectSid | string | The sid of the parent object
regarding | string | what the event is regarding. This is a read only field. Attempting to set this value to anything other than null or empty string will trigger an exception


Expense

Schema: Expense

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
expenseId | int | The unique id of the Expense
memberSid | string | The serial id of this member for which the Expense is created
fromDate | dateTime | The from date of the Expense
toDate | dateTime | The to date of the Expense
createdTimestamp | dateTime | The created timestamp date of the Expense
isExported | boolean | Shows if the Expense is exported
exportedDate | dateTime | The exported date of the Expense
isArchived | boolean | Shows if the expense is archived


ExpenseDetail

Schema: ExpenseDetail

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
expenseDetailId | int | The unique id of the Expense detail
expenseSid | string | The sid of the Expense connected to the detail
paymentMethodId | int | The payment method of the Expense detail, 1=Personal check/cash, 2=Personal credit Card, 3=Company Credit Card
projectSid | string | The sid of the project connected to the detail
accountSid | string | The sid of the account connected to the detail
expenseName | string | The expense name of the Expense detail
expenseDate | dateTime | The expense date of the expense detail
amount | double | The amount of the Expense detail
tax | double | The tax of the Expense detail
description | string | The description of the Expense detail
expenseTypeSid | string | The sid of the Expense type
expenseTypeId | int | The id of the Expense type
createdUserSid | string | The name of the user that created the contact
createdDate | dateTime | The created date for the contact
modifiedUserSid | string | The name of the user that modified the contact
modifiedDate | dateTime | The modified date for the contact
isBillable | boolean | Shows if the Expense detail is billable
airTravelDepartureAirport | string | AirTravel: Departure Airport - Valid only if the expense type is air travel
airTravelArrivalAirport | string | Airfare: Arrival Airport - Valid only if the expense type is air travel
airTravelDepartureDate | dateTime | Airfare: Departure Date - Valid only if the expense type is air travel
airTravelArrivalDate | dateTime | Airfare: Arrival Date - Valid only if the expense type is air travel
autoRentalAgency | string | Auto Rental: Agency Name- Valid only if the expense type is auto rental
autoRentalCity | string | Auto Rental: City- Valid only if the expense type is auto rental
autoFromDate | dateTime | Auto Rental: From Date - Valid only if the expense type is auto rental
autoToDate | dateTime | Auto Rental: To Date - Valid only if the expense type is auto rental
hotelName | string | Hotel: Name - Valid only if the expense type is hotel
hotelCity | string | Hotel: City - Valid only if the expense type is hotel
hotelFromDate | dateTime | Hotel: From Date - Valid only if the expense type is hotel
hotelToDate | dateTime | Hotel: To Date - Valid only if the expense type is hotel
taxiCity | string | Taxi: City - Valid only if the expense type is taxi
taxiLineName | string | Taxi: Line Name - Valid only if the expense type is taxi
telephoneCity | string | Telephone: City - Valid only if the expense type is telephone
telephonePhoneNumber | string | Telephone: Phone Number - Valid only if the expense type is telephone


ExpenseType

Schema: ExpenseType

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
expenseTypeId | int | The id of the expense type
expenseName | string | The expense type name
isDetailMandatory | boolean | Determines if the expense detail is mandatory
isBillable | boolean | Is the task billable by default
isBillableModify | boolean | Can the task billability changed by the user


Issue

Schema: Issue

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
issueId | int | The unique id of the issue in the OfficeClip database
binderSid | string | The unique sid of the binder in the OfficeClip database where the issue belongs
caseNum | string | The fcase number of the issue
title | string | The title of the issue
description | string | The description of the issue
status | string | The salutation of the issue
criticality | string | The title of the issue
category | string | The title of the issue
kind | string | The title of the issue
createdUser | string | The name of the user that created the issue
createdDate | dateTime | The created date for the issue
modifiedUser | string | The name of the user that modified the issue
modifiedDate | dateTime | The modified date for the issue
resolution | string | The resolution of the issue
comments | string | The comments of the issue
assignedTo | string | The assigned to of the issue
udf1 | string | The first user defined field
udf2 | string | The second user defined field
udf3 | string | The third user defined field
udf4 | string | The fourth user defined field
udf5 | string | The fifth user defined field
udf6 | string | The sixth user defined field
udf7 | string | The seventh user defined field
udf8 | string | The eighth user defined field
udf9 | string | The nineth user defined field
udf10 | string | The tenth user defined field


mailMerge

Schema: mailMerge

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
mailMergeId | int | The unique OfficeClip id of the mailmerge campaign
name | string | The name of the mail merge campaign
description | string | The description of meail merge campaign
attachmentSid | string | The sid of the office file that is attached to the campaign


MailMergeRecipients

Schema: MailMergeRecipients

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
mailMergeId | int | The unique OfficeClip id of the mailmerge campaign
contactIds | string | Teh comma separated sid of the contact that is connected to the mail merge campaign


Member

Schema: Member

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
memberId | int | The unique id of the member in OfficeClip
firstName | string | The first name of the member
lastName | string | The last name of the member
emailAddress | string | The email address of the member


MetaInformation

Schema: MetaInformation

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
metaInformationId | int | The unique id of the meta attribute in the OfficeClip database
metaBasicType | int | The type of the field, The following are the field types: 0=unknown, 1=list, 2=text, 3=number, 4=float, 5=date, 6=boolean
internalName | string | The internal name of the attribute, this is how it is represented internally in OfficeClip, so can be used for identification.
schemaName | string | The schema name of the attribute, It matches the column name of the respective schema, for example Contact.xsd column name will match this field.
externalName | string | The user provided name of the attribute, this is how it is shown to the user on the screen.
sectionName | string | The section name where the attributes reside
listChoices | string | The list choices for the list type entry. List choices are represented in the format: text1~text2~text3...
defaultValue | string | The default value of the attribute, date will be encoded in the sortable format. The default value, if present, will be used in all the input forms
isPreferred | boolean | Preferred fields are shown on the list screen
isRequired | boolean | Determines if the value of the attribute is mandatory. If this is true then in any input and edit forms, this value needs to be supplied. If the attribute type is a list, then the list text should not be empty.
isReadonly | boolean | Determines if the value of the attribute is read only. This attribute should not show up in the input screen and should not be editable in the edit screen. Note that both isRequired and isReadOnly cannot be true at the same time. If the client program finds such a case it should immediately throw an exception saying that inconsistent web services values.
isVisible | boolean | Determines if the attribute is visible. This will always be set to true in the current release


Note

Schema: Note

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
noteId | int | The unique id of the note in the OfficeClip database
isPrivate | boolean | Represents if the note is a private note (not shown to anybody else)
subject | string | The subject of the note. Currently this is not represented in the database. This will return first 60 characters of the note description (appended by three dots if needed) and will be ignored when saving to the database
description | string | The description of the note
createdByUserSid | string | The sid of the user who created the note
createdByUserName | string | The name of the user who created the note
createdByTimestamp | dateTime | The timestamp of the user who created the note
modifiedByUserName | string | The name of the user who modified the event
modifiedByUserSid | string | The sid of the user who last modified the note
modifiedByTimestamp | dateTime | The timestamp of the user who last modified the note
parentObjectServiceType | int | The service type of the parent object, -1 if not parent object exist
parentObjectSid | string | The sid of the parent object
regarding | string | what the note is regarding. This is a read only field. Attempting to set this value to anything other than null or empty string will trigger an exception


Organization

Schema: Organization

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
orgId | int | The unique id of the organization in the OfficeClip database where the account belongs
orgName | string | The name of the organization
orgType | int | The type of the organization. This could either be organization or division
lastUpdatedByUserId | int | The user id of the user that last updated the organization
addressId | int | The OfficeClip internal id of the address that is attached to the organization
gdf1Name | string | The name of the first organization defined field. Group defined field value can be put for each user (e.g. employee id).
gdf2Name | string | The name of the second organization defined field.
gdf3Name | string | The name of the third organization defined field.
gdf4Name | string | The name of the fourth organization defined field.
gdf5Name | string | The name of the fifth organization defined field.
parentGroupId | int | The parent organization id of the current organization
timezoneId | int | The OfficeClip internal id of the organization timezone


PayrollCategory

Schema: PayrollCategory

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
payrollCategoryId | int | The unique id of the payroll category detail
payrollCode | string | The payroll code
payrollFullName | string | The payroll full name
notes | string | The payroll notes


Project

Schema: Project

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
projectId | int | The unique id of the project
accountSid | string | The account sid of the project
projectName | string | The project name
id | string | The project user given project id
contactPerson | string | The contact person for the project
contactPhone | string | The contact phone for the project
startDate | dateTime | The start date for the project
endDate | dateTime | The end date for the project
percentCompleted | double | The percentage contact for the project
budgetedHours | double | The budgeted hours for the project
budgetedAmount | double | The budgeted amount for the project
amountSpent | string | The amount spent for the project
notes | string | The notes for the project
isActive | boolean | Shows if the project is active
screenName | string | The screen name for the project


ReturnValue

Schema: ReturnValue

Name | Type | Comment
sid | string | The serial id of this service type
id | int | The OfficeClip internal id
lastUpdateTime | dateTime | The last update time
errorNumber | int | The error number, it will be 0 for success, -1 for error and -2 for warning
errorDescription | string | The error description, it should be empty for success


ServiceItem

Schema: ServiceItem

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
taskId | int | The id of the service item
taskCode | string | The task code (short name for the task)
taskName | string | The full name of the task
projectSid | string | The project sid of the task
accountSid | string | The account sid of the task
isBillable | boolean | Is the task billable by default
isBillableModify | boolean | Can the task billability changed by the user


SystemInfo

Schema: SystemInfo

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
orgSid | string | The unique id of the organization in the OfficeClip database where the contact belongs
orgName | string | The name of the organization
orgType | int | The type of the organization. This could either be organization or division
userSid | string | The user sid of the current login user
userName | string | The user name of the login user
isAdministrator | boolean | Shows if the current logged in user is an administrator
serialNumber | string | Get the serial number of the installation. The serial number is unique across all installation
isExpress | boolean | Test if the current installation is an express installation
isEvaluation | boolean | Test if the current installation is an evaluation installation
productName | string | Get the product name for OfficeClip installation
productVersion | string | Get the product version for OfficeClip installation
outlookVersion | string | Get the version number of the compatible outlook add in that will work with this product. The outlook add in web service client must call this to match with the first two digits of its own version number.
quickBooksVersion | string | Get the version number of the compatible Quickbooks add in that will work with this product. The quickbooks add in web service client must call this to match with the first two digits of its own version number.
microsoftAccountingVersion | string | Get the version number of the compatible MS Accounting add in that will work with this product. The MS Accounting add in web service client must call this to match with the first two digits of its own version number.
offlineTimeExpenseVersion | string | Get the version number of the compatible Offline Time Expense that will work with this product. The Offline Time Expense add in web service client must call this to match with the first two digits of its own version number.
allowedApplications | string | Get the Allowed application ids in a comma separated string. The value of -1 means all applications are allowed (Premium Suite)


Task

Schema: Task

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
taskId | int | The unique id of the task in the OfficeClip database
taskOwnerSid | string | The sid of the owner of the task. Usually this is the creator id unless the task is assigned to a person. In that case it will be the assigned person id
taskOwnerName | string | The name of the owner of the task. Usually this is the creator id unless the task is assigned to a person. In that case it will be the assigned person name
taskTypeId | int | The type of the task, valid values are None=0, Telephone=1, ToDo=2, Email=3, Other=4
taskTypeName | string | The name of the task Type
taskStatusId | int | The status of the task, valid values are None=0, In Progress=1, Completed=2, Pending=3, Waiting=4, Other=5
taskStatusName | string | The name of the task Type
taskPriorityId | int | The priority of the task, valid values are None=0, High=1, Medium=2, Low=3, Other=4
taskPriorityName | string | The name of the task priority
dueDate | dateTime | The date time when the task is due
startDate | dateTime | The date time when the task starts
completionDate | dateTime | The date time when the task completes
percentComplete | double | Represents what percentage of task is completed
estimatedDuration | int | The estimated duration of the task in minutes
actualDuration | int | The actual duration of the task in minutes
repeatTextInfo | string | The text of the repeat information if the task repeats
isReminderSelected | boolean | Shows if the reminder is selected for the task
whoToRemind | string | The string representation of who needs to be reminded
remindAtDateTime | dateTime | The date and time when the reminder should occur.
isPrivate | boolean | Represents if the task is a private task (not shown to anybody else)
subject | string | The subject of the task
description | string | The description of the task
createdByUserName | string | The name of the user who created the task
createdByUserSid | string | The sid of the user who created the task
createdByTimestamp | dateTime | The timestamp of the user who created the task
modifiedByUserName | string | The name of the user who modified the event
modifiedByUserSid | string | The sid of the user who last modified the task
modifiedByTimestamp | dateTime | The timestamp of the user who last modified the task
parentObjectServiceType | int | The service type of the parent object, -1 if not parent object exist
parentObjectSid | string | The sid of the parent object
regarding | string | what the event is regarding. This is a read only field. Attempting to set this value to anything other than null or empty string will trigger an exception
taskAssignments | string | People who the task is assigned to. Valid format is: name1(emailAddress1), name2(emailAddress2)... etc.


TemplateParentChild

Schema: TemplateParentChild

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
templateType | int | The template type
itemConstant | int | The item constant
name | string | The name of the parent
values | string | The space separated list of children


Timesheet

Schema: Timesheet

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
timesheetId | int | The unique id of the timesheet
memberSid | string | The serial id of this member for which the timesheet is created
fromDate | dateTime | The from date of the timesheet
toDate | dateTime | The to date of the timesheet
createdTimestamp | dateTime | The created timestamp date of the timesheet
isExported | boolean | Shows if the timesheet is exported
exportedDate | dateTime | The exported date of the timesheet
isArchived | boolean | Shows if the timesheet is archived


TimesheetDetail

Schema: TimesheetDetail

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
timesheetDetailId | int | The unique id of the timesheet detail
timesheetSid | string | The sid of the timesheet connected to the detail
payrollCategorySid | string | The payroll category id of the timesheet detail
projectSid | string | The sid of the project connected to the detail
accountSid | string | The sid of the account connected to the detail
serviceItemDate | dateTime | The service date of the timesheet detail
serviceItemSid | string | The sid of the service item connected to the detail
taskCode | string | The task code for the timesheet detail
taskName | string | The task name for the timesheet detail
timeDuration | double | The time duration for the timesheet detail
taskDescription | string | The task description for the timesheet detail
createdUserSid | string | The name of the user that created the contact
createdDate | dateTime | The created date for the contact
modifiedUserSid | string | The name of the user that modified the contact
modifiedDate | dateTime | The modified date for the contact
isBillable | boolean | Shows if the timesheet detail is billable


TrackerBinder

Schema: TrackerBinder

Name | Type | Comment
sid | string | The serial id of this service type
isLock | boolean | Determines if the column can be edited
tag | string | Used by OfficeClip to pass specific information
binderId | int | The unique id of the binder in the OfficeClip database
binderName | string | The name of the issue binder
isActive | boolean | Determines if the tracker binder is active (or archived)
numCases | int | The number of cases in this binder
createdByUserSid | string | The sid of the user who created the tracker binder
createdByTimestamp | dateTime | The timestamp of the user who created the tracker binder
orgSid | string | The serial number of the organization which owns the binder


OfficeClip.Service.Web Namespace

[image]

OfficeClip Web Services Documentation
OfficeClip.Service.Web Namespace

[This is preliminary documentation and is subject to change.]

This namespace drives the OfficeClip generic webservice.

Classes

Class Description
Public class Driver
The driver class drives all the web services calls. Each web service communicates with the outside world using simple data types. Complex data types are encoded in the xml format which is same as the serialized dataset. Instead of xml, the consumer can also use the dataset (in .net clients). Most services has a service type as argument. The service group determines which entity is addressed (example group, attachment, contact etc.). The service type is an enumerated type in OfficeClip, the integer value of which is used in the web service. Following are the service types that are currently implemented.
Service Item(Id) | Description
Tracker Binder(1) | The OfficeClip Tracker Binder.
Tracker Issue(4) | The OfficeClip Tracker Issue.
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Member(11) | The OfficeClip Member
Organization(13) | The OfficeClip Organization
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Template Parent Child(23) | The parent child values of the template. The service sub type for this type is the template type.
Attachment(24) | Document attachments with various applications
Return Value(25) | The return value format for various operations (e.g. Insert, Update)
Template Key Value(27) | The Template key value information (used to merge a template)
Mail Merge Campaign(28) | The mail merge campaign information
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information
System Information(30) | Provides Session and System Information
Account(31) | Account Information
Project(32) | Project information
Service Item(33) | Services Item information
Timesheet(34) | Timesheet information
Timesheet Detail(35) | Timesheet Detail information. The service subtype for this type is Timesheet (34)
Expense(36) | Expense information
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Expense Type(38) | The Expense Type information. Expense type categories are: 1=air travel, 2=hotel, 3=auto rental, 4=taxi, 5=telephone, 6+ = other
Meta Information(39) | Provides information regarding field name, field type, section name, list choices, default value, is required, is readonly and is visible for entities like contacts, accounts, opportunities etc.
Payroll Category(40) | Provides various payroll categories like regular, exempt etc.
Some web services uses a string called the serial id (sid). The serial id is a globally unique string across all OfficeClip installation, application and data rows.


Driver Class

[image]

OfficeClip Web Services Documentation
Driver Class
Members Example See Also

[This is preliminary documentation and is subject to change.]

The driver class drives all the web services calls. Each web service communicates with the outside world using simple data types. Complex data types are encoded in the xml format which is same as the serialized dataset. Instead of xml, the consumer can also use the dataset (in .net clients). Most services has a service type as argument. The service group determines which entity is addressed (example group, attachment, contact etc.). The service type is an enumerated type in OfficeClip, the integer value of which is used in the web service. Following are the service types that are currently implemented.
Service Item(Id) | Description
Tracker Binder(1) | The OfficeClip Tracker Binder.
Tracker Issue(4) | The OfficeClip Tracker Issue.
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Member(11) | The OfficeClip Member
Organization(13) | The OfficeClip Organization
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Template Parent Child(23) | The parent child values of the template. The service sub type for this type is the template type.
Attachment(24) | Document attachments with various applications
Return Value(25) | The return value format for various operations (e.g. Insert, Update)
Template Key Value(27) | The Template key value information (used to merge a template)
Mail Merge Campaign(28) | The mail merge campaign information
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information
System Information(30) | Provides Session and System Information
Account(31) | Account Information
Project(32) | Project information
Service Item(33) | Services Item information
Timesheet(34) | Timesheet information
Timesheet Detail(35) | Timesheet Detail information. The service subtype for this type is Timesheet (34)
Expense(36) | Expense information
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Expense Type(38) | The Expense Type information. Expense type categories are: 1=air travel, 2=hotel, 3=auto rental, 4=taxi, 5=telephone, 6+ = other
Meta Information(39) | Provides information regarding field name, field type, section name, list choices, default value, is required, is readonly and is visible for entities like contacts, accounts, opportunities etc.
Payroll Category(40) | Provides various payroll categories like regular, exempt etc.
Some web services uses a string called the serial id (sid). The serial id is a globally unique string across all OfficeClip installation, application and data rows.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public class Driver
Visual Basic (Declaration)
Public Class Driver
Visual C++
public ref class Driver

Examples

CopyCreates a new connection to the Web Service
public static WebServiceClient.Generic.OfficeClipGeneric CreateConnection()
{
 // create an instance of the web service client
 WebServiceClient.Generic.OfficeClipGeneric ofg =
    new WebServiceClient.Generic.OfficeClipGeneric();
 // Create a cookie container so that the session can persist on the server
 ofg.CookieContainer = new System.Net.CookieContainer();
 return ofg;
}
CopyLogin to the Web Service
public static void Login(
 WebServiceClient.Generic.OfficeClipGeneric ofg, string emailAddress, string password
 )
{
 try
 {
    // try using the webservice to validate the user, if successful,
    // an user session will be created
     string msg = ofg.ValidateUser(emailAddress, password);
    if (msg == string.Empty)
     Console.WriteLine("Login Successful");
    else
     Console.WriteLine("Login Failed: " + msg);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}
CopyGet the Organization data
public static DataSet GetOrganizationData(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 13 is for organization data
    ds = ofg.GetDataSet(13, -1, string.Empty, string.Empty, string.Empty, -1);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}
CopyGets the template parent child for contacts
public static DataSet GetTemplateParentChild(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 23 is for parent child template
    // Service sub type of 15 is for template type contact
    ds = ofg.GetDataSet(23, 15, string.Empty, string.Empty, string.Empty, -1);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}
CopyGets numbered rows from all the contacts
public static DataSet GetAllContacts(
 WebServiceClient.Generic.OfficeClipGeneric ofg, string filter
 )
{
 DataSet ds = null;
 try
 {
  // Service Type 18 is for Contact
  // it also returns the columns firstName, lastName and title
     ds = ofg.GetDataSet(18, -1, "", filter, string.Empty, -1);
    // ds = ofg.GetDataSet(18, -1, "firstName,lastName,title", string.Empty, string.Empty, -1);
 }
 catch (SoapException ex)
 {
  Console.WriteLine(ex.Message);
 }
 return ds;
}
CopyInserts a campaign attachment
/// <summary>
///  Inserts a campaign. The campaign is previously saved as c:\temp\test.doc
///  This will insert the campaign document in OfficeClip via the web service.
/// A mailmerge campaign will be stored in OfficeClip as attachemtn
/// </summary>
/// <param name="ofg">Reference to the web service proxy</param>
public static void InsertCampaignAttachment(
 WebServiceClient.Generic.OfficeClipGeneric ofg,
 string sid
 )
{
 DataSet ds = null;
 try
 {
    // Retrieve the schema for service type 24 (attachments)
    StringReader sr = new StringReader(ofg.GetXmlSchema(24));
    ds = new DataSet();
    ds.ReadXmlSchema(sr);
    sr.Close();
    // This schema will be used to create a dataset to insert value
    // in OfficeClip.
    ds.Tables.Add(new DataTable());
    DataTable dt = ds.Tables[0];
    DataRow dr = dt.NewRow();
    dr["sid"] = "1";
    dr["fileName"] = "test.doc";
    dr["documentKey"] = "";
    dr["documentDescription"] = "";
    dr["applicationId"] = 27; // The application id 27 is the application id of the campaign
    dr["applicationSecondaryId"] = 1; // secondary id of 1 denotes attachment for mailmerge campaigns
    dr["id"] = sid;
    dr["isZipped"] = false;
    // Open the campaign from the local drive for reading
    FileStream fs = new FileStream(
     @"c:\temp\test.doc",
     FileMode.Open,
     FileAccess.Read
    );
    // Read the file as a set of bytes so it can be serialized by the webservices interface
    // and sent. The webservice will reconstruct the file at the server.
    BinaryReader br = new BinaryReader(fs);
    dr["bytes"] = br.ReadBytes((int)br.BaseStream.Length);
    dt.Rows.Add(dr);
    // Send the file as attachment
    DataSet dsResult = ofg.Insert(24, ds);
    // The schema of the returning dataset can be extracted using the GetSchema call
    // with service type 25 (Return value). For this example we know that there are
    // two columns called sid (unique service id) and errorDescription.
    Console.WriteLine("Serial Id: " + (string)dsResult.Tables[0].Rows[0]["sid"]);
    Console.WriteLine("Error: " + (string)dsResult.Tables[0].Rows[0]["errorDescription"]);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}
CopyDeletes a campaign attachment
public static DataSet DeleteCampaignAttachment(
 WebServiceClient.Generic.OfficeClipGeneric ofg,
 string sid
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 24 is for campaign data
    bool status = ofg.Delete(24, sid);
    Console.WriteLine((status) ? "Delete Successful" : "Delete Failed");
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}
CopyTest if the session exists
public static void IsSessionExists(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 try
 {
    bool exists = ofg.IsSessionExists();
    Console.WriteLine((exists) ? "Session Found" : "Session could not be found");
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}
CopyEnd the session to the Web Service
public static void EndConnection(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 try
 {
    ofg.SessionOver();
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}

Inheritance Hierarchy

System..::.Object
OfficeClip.Service.Web..::.Driver

See Also

Driver Members
OfficeClip.Service.Web Namespace


Driver Members

[image] [image]

OfficeClip Web Services Documentation
Driver Members
Driver Class Constructors Methods See Also

[This is preliminary documentation and is subject to change.]

The Driver type exposes the following members.

Constructors

 | Name | Description
Public method | Driver |

Methods

Name Description
Public method Delete
Deletes a row in the OfficeClip based on the service id.
Service Item(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Account(31) | Account Information
Project(32) | Project information
Service Item(33) | Services Item information
Expense(36) | Expense information
Expense Type(38) | The expense type information
Public method Equals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected method Finalize
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.)
Public method GetDataByKey
Gets a data based on a key. This call is valid for the following service types. This call accepts a space separated list of sid and returns the data in the datatable. If a particular sid data cannot be extracted, it sets the tag column of the dataset to the error string (otherwise the tag column is set to an empty string).
Entity(Id) | Description
Task(8) | The OfficeClip Task. If a subtype is specified then the sids supplied should be of that subtype. Only tasks that corresponds to the subtype will be returned.
Organization(13) | The OfficeClip Organization
Event(14) | The OfficeClip Calendar Events. If a subtype is specified then the sids supplied should be of that subtype. Only events that corresponds to the subtype will be returned.
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. If a subtype is specified then the sids supplied should be of that subtype. Only notes that corresponds to the subtype will be returned.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
Template Key Value(27) | The Template key value information (used to merge a template). The serviceSubType of 15 represents the template type of ContactManager
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Timesheet(34) | Timesheet information.
Timesheet Detail(35) | Timesheet Detail information. The service subtype for this type is Timesheet (34)
Expense(36) | Expense information.
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Public method GetDataSet
Returns the complete dataset for the requested service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Binder(1) | The OfficeClip Tracker Binder.
Tracker Issue(4) | The OfficeClip Tracker Issue. A filter must be supplied in the form BinderId=1 (for example)
Task(8) | The OfficeClip Task. Note that the subtype should be -1 for this call so this call returns all tasks.
Organization(13) | The OfficeClip Organization. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Event(14) | The OfficeClip Calendar Events. Note that the subtype should be -1 for this call so this call returns all events.
Contact(18) | The contact management metaentity. If the filter is specified, it should be in the format, Search:value or Filter:value. The first type does a search over all the records in the database and the second type searches by a filter that is created in OfficeClip.
Note(20) | The OfficeClip Notes Entity. Note that the subtype should be -1 for this call so this call returns all notes.
Mail Merge Campaign(28) | The mail merge campaign information. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
System Information(30) | Provides Session and System Information
Account(31) | Account Information. If the option parameter is passed as 1, then only restricted accounts, i.e. the account that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active accounts will be shown.
Project(32) | The Project information. If the option parameter is passed as 1, then only restricted projects, i.e. the project that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active projects will be shown. A non-administrator will always only see the restricted projects (regardless of the option value).
Service Item(33) | Services Item information
Timesheet(34) | Timesheet information
Expense(36) | Timesheet information
Expense Type(38) | Expense type information
Meta Information(39) | Provides the meta information. The service subtype needs to be supplied, which is currently valid for Contact(18) and Tracker Binder(1) only. If the sub service type of Tracker Binder is used, a filter must be supplied in the form BinderId=1 (for example)
Payroll Category(40) | Provides the payroll category
Public method GetHashCode
Serves as a hash function for a particular type. GetHashCode()()() is suitable for use in hashing algorithms and data structures like a hash table.
(Inherited from Object.)
Public method GetType
Gets the Type of the current instance.
(Inherited from Object.)
Public method GetXmlData
Returns the Xml for the requested service type. This call is valid for all the service types of the GetDataSet call (see GetDataSet(Int32, Int32, String, String, String, Int32). The output is just an xml string instead of the dataset.
Public method GetXmlDataByKey
Gets the xml string of a single row of data. This call is valid for all the service types of the GetDataSet call (see GetDataByKey(Int32, Int32, String). The output is just an xml string instead of the dataset.
Public method GetXmlSchema
Gets the Xml Schema for a particular service type. If the service group is not implemented, a SOAPException is thrown. This call is valid for all the service types that are implemented (see class description).
Public method Insert
Inserts data into OfficeClip based on a service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Issue(4) | The OfficeClip Tracker Issue. Note that the binder Sid must be supplied for each row in order to insert the issue in a binder.
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information. Note that the endDate of the period will automatically be calculated. It will return an error if the startDate is not within a range of valid startDate for the timesheet.
Timesheet Detail(35) | Timesheet Detail information
Expense(36) | Expense information
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Public method InsertXml
Inserts data into OfficeClip based on a service type. This call is same as the Insert call (that accepts a dataset as a parameter), the only difference is that this call accepts a serialized dataset. See description of the Insert call to find out which service items are accepted by this call.
Public method IsSessionExists
Checks whether the session exists. This function can be called periodically to make sure that the session has not timed out. If the session does not exists, most web service calls will fail unless the session is recreated.
Protected method MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public method SessionOver
Destroys the session and effectively logs the user out.
Public method SetOrganization
Changes the OfficeClip organization in the session. Succeeding calls are made to the new organization. Note that this does not change the organization in the regular OfficeClip login.
Public method ToString
Returns a String that represents the current Object.
(Inherited from Object.)
Public method Update
Updates OfficeClip data using a key. Update returns a bool showing whether the update succeeded. Note that if a null value of any column is suppled, that column will not get updated in OfficeClip.
Entity(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information, currently only the exported status of the timesheet can be set using this method
Expense(36) | Expense information. currently only the exported status of the expense can be set using this method
Public method ValidateUser
Validates the user and if the user gets validated, the session is created. If the validation is successful, the organization is set to the last organization that is opened in the OfficeClip user interface.

See Also

Driver Class
OfficeClip.Service.Web Namespace


Driver Constructor

[image]

OfficeClip Web Services Documentation
Driver Constructor
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Initializes a new instance of the Driver class.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public Driver()
Visual Basic (Declaration)
Public Sub New
Visual C++
public:
Driver()

See Also

Driver Class
OfficeClip.Service.Web Namespace


Driver Methods

[image] [image]

OfficeClip Web Services Documentation
Driver Methods
Driver Class See Also

[This is preliminary documentation and is subject to change.]

The Driver type exposes the following methods.

Methods

Name Description
Public method Delete
Deletes a row in the OfficeClip based on the service id.
Service Item(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Account(31) | Account Information
Project(32) | Project information
Service Item(33) | Services Item information
Expense(36) | Expense information
Expense Type(38) | The expense type information
Public method Equals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected method Finalize
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.)
Public method GetDataByKey
Gets a data based on a key. This call is valid for the following service types. This call accepts a space separated list of sid and returns the data in the datatable. If a particular sid data cannot be extracted, it sets the tag column of the dataset to the error string (otherwise the tag column is set to an empty string).
Entity(Id) | Description
Task(8) | The OfficeClip Task. If a subtype is specified then the sids supplied should be of that subtype. Only tasks that corresponds to the subtype will be returned.
Organization(13) | The OfficeClip Organization
Event(14) | The OfficeClip Calendar Events. If a subtype is specified then the sids supplied should be of that subtype. Only events that corresponds to the subtype will be returned.
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. If a subtype is specified then the sids supplied should be of that subtype. Only notes that corresponds to the subtype will be returned.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
Template Key Value(27) | The Template key value information (used to merge a template). The serviceSubType of 15 represents the template type of ContactManager
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Timesheet(34) | Timesheet information.
Timesheet Detail(35) | Timesheet Detail information. The service subtype for this type is Timesheet (34)
Expense(36) | Expense information.
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Public method GetDataSet
Returns the complete dataset for the requested service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Binder(1) | The OfficeClip Tracker Binder.
Tracker Issue(4) | The OfficeClip Tracker Issue. A filter must be supplied in the form BinderId=1 (for example)
Task(8) | The OfficeClip Task. Note that the subtype should be -1 for this call so this call returns all tasks.
Organization(13) | The OfficeClip Organization. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Event(14) | The OfficeClip Calendar Events. Note that the subtype should be -1 for this call so this call returns all events.
Contact(18) | The contact management metaentity. If the filter is specified, it should be in the format, Search:value or Filter:value. The first type does a search over all the records in the database and the second type searches by a filter that is created in OfficeClip.
Note(20) | The OfficeClip Notes Entity. Note that the subtype should be -1 for this call so this call returns all notes.
Mail Merge Campaign(28) | The mail merge campaign information. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
System Information(30) | Provides Session and System Information
Account(31) | Account Information. If the option parameter is passed as 1, then only restricted accounts, i.e. the account that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active accounts will be shown.
Project(32) | The Project information. If the option parameter is passed as 1, then only restricted projects, i.e. the project that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active projects will be shown. A non-administrator will always only see the restricted projects (regardless of the option value).
Service Item(33) | Services Item information
Timesheet(34) | Timesheet information
Expense(36) | Timesheet information
Expense Type(38) | Expense type information
Meta Information(39) | Provides the meta information. The service subtype needs to be supplied, which is currently valid for Contact(18) and Tracker Binder(1) only. If the sub service type of Tracker Binder is used, a filter must be supplied in the form BinderId=1 (for example)
Payroll Category(40) | Provides the payroll category
Public method GetHashCode
Serves as a hash function for a particular type. GetHashCode()()() is suitable for use in hashing algorithms and data structures like a hash table.
(Inherited from Object.)
Public method GetType
Gets the Type of the current instance.
(Inherited from Object.)
Public method GetXmlData
Returns the Xml for the requested service type. This call is valid for all the service types of the GetDataSet call (see GetDataSet(Int32, Int32, String, String, String, Int32). The output is just an xml string instead of the dataset.
Public method GetXmlDataByKey
Gets the xml string of a single row of data. This call is valid for all the service types of the GetDataSet call (see GetDataByKey(Int32, Int32, String). The output is just an xml string instead of the dataset.
Public method GetXmlSchema
Gets the Xml Schema for a particular service type. If the service group is not implemented, a SOAPException is thrown. This call is valid for all the service types that are implemented (see class description).
Public method Insert
Inserts data into OfficeClip based on a service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Issue(4) | The OfficeClip Tracker Issue. Note that the binder Sid must be supplied for each row in order to insert the issue in a binder.
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information. Note that the endDate of the period will automatically be calculated. It will return an error if the startDate is not within a range of valid startDate for the timesheet.
Timesheet Detail(35) | Timesheet Detail information
Expense(36) | Expense information
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)
Public method InsertXml
Inserts data into OfficeClip based on a service type. This call is same as the Insert call (that accepts a dataset as a parameter), the only difference is that this call accepts a serialized dataset. See description of the Insert call to find out which service items are accepted by this call.
Public method IsSessionExists
Checks whether the session exists. This function can be called periodically to make sure that the session has not timed out. If the session does not exists, most web service calls will fail unless the session is recreated.
Protected method MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public method SessionOver
Destroys the session and effectively logs the user out.
Public method SetOrganization
Changes the OfficeClip organization in the session. Succeeding calls are made to the new organization. Note that this does not change the organization in the regular OfficeClip login.
Public method ToString
Returns a String that represents the current Object.
(Inherited from Object.)
Public method Update
Updates OfficeClip data using a key. Update returns a bool showing whether the update succeeded. Note that if a null value of any column is suppled, that column will not get updated in OfficeClip.
Entity(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information, currently only the exported status of the timesheet can be set using this method
Expense(36) | Expense information. currently only the exported status of the expense can be set using this method
Public method ValidateUser
Validates the user and if the user gets validated, the session is created. If the validation is successful, the organization is set to the last organization that is opened in the OfficeClip user interface.

See Also

Driver Class
OfficeClip.Service.Web Namespace


Delete Method

[image]

OfficeClip Web Services Documentation
Driver..::.Delete Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Deletes a row in the OfficeClip based on the service id.
Service Item(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Account(31) | Account Information
Project(32) | Project information
Service Item(33) | Services Item information
Expense(36) | Expense information
Expense Type(38) | The expense type information

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public bool Delete(
    int serviceType,
    string sid
)
Visual Basic (Declaration)
Public Function Delete ( _
    serviceType As Integer, _
    sid As String _
) As Boolean
Visual C++
public:
bool Delete(
    int serviceType,
    String^ sid
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.
sid
Type: System..::.String
The serial id of the organization

Return Value

True if successfully deleted, false otherwise.

Examples

CopyDeletes a campaign attachment
public static DataSet DeleteCampaignAttachment(
 WebServiceClient.Generic.OfficeClipGeneric ofg,
 string sid
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 24 is for campaign data
    bool status = ofg.Delete(24, sid);
    Console.WriteLine((status) ? "Delete Successful" : "Delete Failed");
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


GetDataByKey Method

[image]

OfficeClip Web Services Documentation
Driver..::.GetDataByKey Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Gets a data based on a key. This call is valid for the following service types. This call accepts a space separated list of sid and returns the data in the datatable. If a particular sid data cannot be extracted, it sets the tag column of the dataset to the error string (otherwise the tag column is set to an empty string).
Entity(Id) | Description
Task(8) | The OfficeClip Task. If a subtype is specified then the sids supplied should be of that subtype. Only tasks that corresponds to the subtype will be returned.
Organization(13) | The OfficeClip Organization
Event(14) | The OfficeClip Calendar Events. If a subtype is specified then the sids supplied should be of that subtype. Only events that corresponds to the subtype will be returned.
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. If a subtype is specified then the sids supplied should be of that subtype. Only notes that corresponds to the subtype will be returned.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
Template Key Value(27) | The Template key value information (used to merge a template). The serviceSubType of 15 represents the template type of ContactManager
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Timesheet(34) | Timesheet information.
Timesheet Detail(35) | Timesheet Detail information. The service subtype for this type is Timesheet (34)
Expense(36) | Expense information.
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public DataSet GetDataByKey(
    int serviceType,
    int serviceSubType,
    string sids
)
Visual Basic (Declaration)
Public Function GetDataByKey ( _
    serviceType As Integer, _
    serviceSubType As Integer, _
    sids As String _
) As DataSet
Visual C++
public:
DataSet^ GetDataByKey(
    int serviceType,
    int serviceSubType,
    String^ sids
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.
serviceSubType
Type: System..::.Int32
The service subtype (if present, otherwise the value is -1)
sids
Type: System..::.String
A space separated list of sid for which the data is requested.

Return Value

The dataset for the data requested. Normally the first table contains the requested data. If one of the sid returns an error, the tag field will contain the error. Consuming application must check the tag field before proceeding with the data

Examples

CopyGets the template parent child for contacts
public static DataSet GetTemplateParentChild(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 23 is for parent child template
    // Service sub type of 15 is for template type contact
    ds = ofg.GetDataSet(23, 15, string.Empty, string.Empty, string.Empty, -1);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


GetDataSet Method

[image]

OfficeClip Web Services Documentation
Driver..::.GetDataSet Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Returns the complete dataset for the requested service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Binder(1) | The OfficeClip Tracker Binder.
Tracker Issue(4) | The OfficeClip Tracker Issue. A filter must be supplied in the form BinderId=1 (for example)
Task(8) | The OfficeClip Task. Note that the subtype should be -1 for this call so this call returns all tasks.
Organization(13) | The OfficeClip Organization. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Event(14) | The OfficeClip Calendar Events. Note that the subtype should be -1 for this call so this call returns all events.
Contact(18) | The contact management metaentity. If the filter is specified, it should be in the format, Search:value or Filter:value. The first type does a search over all the records in the database and the second type searches by a filter that is created in OfficeClip.
Note(20) | The OfficeClip Notes Entity. Note that the subtype should be -1 for this call so this call returns all notes.
Mail Merge Campaign(28) | The mail merge campaign information. values of columnNumbers, filterName and sortClause must be passed as empty string and option must be passed as -1.
Template Parent Child(23) | The parent child values of the template. The servicesubtyppe is the template type
System Information(30) | Provides Session and System Information
Account(31) | Account Information. If the option parameter is passed as 1, then only restricted accounts, i.e. the account that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active accounts will be shown.
Project(32) | The Project information. If the option parameter is passed as 1, then only restricted projects, i.e. the project that the current user can see in TE module, will be shown. If the option parameter is passed as -1, then all active projects will be shown. A non-administrator will always only see the restricted projects (regardless of the option value).
Service Item(33) | Services Item information
Timesheet(34) | Timesheet information
Expense(36) | Timesheet information
Expense Type(38) | Expense type information
Meta Information(39) | Provides the meta information. The service subtype needs to be supplied, which is currently valid for Contact(18) and Tracker Binder(1) only. If the sub service type of Tracker Binder is used, a filter must be supplied in the form BinderId=1 (for example)
Payroll Category(40) | Provides the payroll category

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public DataSet GetDataSet(
    int serviceType,
    int serviceSubType,
    string columnNames,
    string filterName,
    string sortClause,
    int option
)
Visual Basic (Declaration)
Public Function GetDataSet ( _
    serviceType As Integer, _
    serviceSubType As Integer, _
    columnNames As String, _
    filterName As String, _
    sortClause As String, _
    option As Integer _
) As DataSet
Visual C++
public:
DataSet^ GetDataSet(
    int serviceType,
    int serviceSubType,
    String^ columnNames,
    String^ filterName,
    String^ sortClause,
    int option
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.
serviceSubType
Type: System..::.Int32
The service subtype. A value of -1 is passed if there is no subtype
columnNames
Type: System..::.String
A comma separated list of column names to be sent to the output. Sends all the columns if empty.
filterName
Type: System..::.String
The name of the filter that is used to filter the data. Note that the filter name can be dependent on the implementation. Empty value returns all the data.
sortClause
Type: System..::.String
A sort clause in sql format (e.g. LastName DESC). Note that this may not be supported for all service ids. An empty string returns data sorted by a default order.
option
Type: System..::.Int32
A bit wise variable to pass various options. -1 must be passed in this field if the option is undefined.

Return Value

The dataset for the data requested. Normally the first table contains the requested data.

Examples

CopyGet the Organization data
public static DataSet GetOrganizationData(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 DataSet ds = null;
 try
 {
    // Service Type 13 is for organization data
    ds = ofg.GetDataSet(13, -1, string.Empty, string.Empty, string.Empty, -1);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
 return ds;
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


GetXmlData Method

[image]

OfficeClip Web Services Documentation
Driver..::.GetXmlData Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Returns the Xml for the requested service type. This call is valid for all the service types of the GetDataSet call (see GetDataSet(Int32, Int32, String, String, String, Int32). The output is just an xml string instead of the dataset.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public string GetXmlData(
    int serviceType,
    int serviceSubType,
    string columnNumbers,
    string filterName,
    string sortClause,
    int option
)
Visual Basic (Declaration)
Public Function GetXmlData ( _
    serviceType As Integer, _
    serviceSubType As Integer, _
    columnNumbers As String, _
    filterName As String, _
    sortClause As String, _
    option As Integer _
) As String
Visual C++
public:
String^ GetXmlData(
    int serviceType,
    int serviceSubType,
    String^ columnNumbers,
    String^ filterName,
    String^ sortClause,
    int option
)

Parameters

serviceType
Type: System..::.Int32
see GetDataSet(Int32, Int32, String, String, String, Int32)
serviceSubType
Type: System..::.Int32
see GetDataSet(Int32, Int32, String, String, String, Int32)
columnNumbers
Type: System..::.String
see GetDataSet(Int32, Int32, String, String, String, Int32)
filterName
Type: System..::.String
see GetDataSet(Int32, Int32, String, String, String, Int32)
sortClause
Type: System..::.String
see GetDataSet(Int32, Int32, String, String, String, Int32)
option
Type: System..::.Int32
see GetDataSet(Int32, Int32, String, String, String, Int32)

Return Value

The Xml for the data requested. This is the serialized string for the first table of the dataset containing the requested data.

See Also

Driver Class
OfficeClip.Service.Web Namespace
Driver..::.GetDataSet(Int32, Int32, String, String, String, Int32)


GetXmlDataByKey Method

[image]

OfficeClip Web Services Documentation
Driver..::.GetXmlDataByKey Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Gets the xml string of a single row of data. This call is valid for all the service types of the GetDataSet call (see GetDataByKey(Int32, Int32, String). The output is just an xml string instead of the dataset.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public string GetXmlDataByKey(
    int serviceType,
    int serviceSubType,
    string sids
)
Visual Basic (Declaration)
Public Function GetXmlDataByKey ( _
    serviceType As Integer, _
    serviceSubType As Integer, _
    sids As String _
) As String
Visual C++
public:
String^ GetXmlDataByKey(
    int serviceType,
    int serviceSubType,
    String^ sids
)

Parameters

serviceType
Type: System..::.Int32
see GetDataByKey(Int32, Int32, String)
serviceSubType
Type: System..::.Int32
see GetDataByKey(Int32, Int32, String)
sids
Type: System..::.String
see GetDataByKey(Int32, Int32, String)

Return Value

The Xml string for the data requested. This is the serialized string for the first table of the dataset containing the requested data.

See Also

Driver Class
OfficeClip.Service.Web Namespace
Driver..::.GetDataByKey(Int32, Int32, String)


GetXmlSchema Method

[image]

OfficeClip Web Services Documentation
Driver..::.GetXmlSchema Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Gets the Xml Schema for a particular service type. If the service group is not implemented, a SOAPException is thrown. This call is valid for all the service types that are implemented (see class description).

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public string GetXmlSchema(
    int serviceType
)
Visual Basic (Declaration)
Public Function GetXmlSchema ( _
    serviceType As Integer _
) As String
Visual C++
public:
String^ GetXmlSchema(
    int serviceType
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.

Return Value

The Xml Schema for the service type. The schema returned is same as the underlying dataset schema.

See Also

Driver Class
OfficeClip.Service.Web Namespace


Insert Method

[image]

OfficeClip Web Services Documentation
Driver..::.Insert Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Inserts data into OfficeClip based on a service type. This call is valid for the following service types.
Entity(Id) | Description
Tracker Issue(4) | The OfficeClip Tracker Issue. Note that the binder Sid must be supplied for each row in order to insert the issue in a binder.
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information. Note that the endDate of the period will automatically be calculated. It will return an error if the startDate is not within a range of valid startDate for the timesheet.
Timesheet Detail(35) | Timesheet Detail information
Expense(36) | Expense information
Expense Detail(37) | Expense Detail information. The service subtype for this type is Expense (36)

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public DataSet Insert(
    int serviceType,
    DataSet ds
)
Visual Basic (Declaration)
Public Function Insert ( _
    serviceType As Integer, _
    ds As DataSet _
) As DataSet
Visual C++
public:
DataSet^ Insert(
    int serviceType,
    DataSet^ ds
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.
ds
Type: System.Data..::.DataSet
The dataset containing the data to be inserted. The data is available in the first table of the dataset.

Return Value

The output dataset. The schema of the dataset is the schema for the service type "Return Value".

Examples

CopyInserts a campaign attachment
/// <summary>
///  Inserts a campaign. The campaign is previously saved as c:\temp\test.doc
///  This will insert the campaign document in OfficeClip via the web service.
/// A mailmerge campaign will be stored in OfficeClip as attachemtn
/// </summary>
/// <param name="ofg">Reference to the web service proxy</param>
public static void InsertCampaignAttachment(
 WebServiceClient.Generic.OfficeClipGeneric ofg,
 string sid
 )
{
 DataSet ds = null;
 try
 {
    // Retrieve the schema for service type 24 (attachments)
    StringReader sr = new StringReader(ofg.GetXmlSchema(24));
    ds = new DataSet();
    ds.ReadXmlSchema(sr);
    sr.Close();
    // This schema will be used to create a dataset to insert value
    // in OfficeClip.
    ds.Tables.Add(new DataTable());
    DataTable dt = ds.Tables[0];
    DataRow dr = dt.NewRow();
    dr["sid"] = "1";
    dr["fileName"] = "test.doc";
    dr["documentKey"] = "";
    dr["documentDescription"] = "";
    dr["applicationId"] = 27; // The application id 27 is the application id of the campaign
    dr["applicationSecondaryId"] = 1; // secondary id of 1 denotes attachment for mailmerge campaigns
    dr["id"] = sid;
    dr["isZipped"] = false;
    // Open the campaign from the local drive for reading
    FileStream fs = new FileStream(
     @"c:\temp\test.doc",
     FileMode.Open,
     FileAccess.Read
    );
    // Read the file as a set of bytes so it can be serialized by the webservices interface
    // and sent. The webservice will reconstruct the file at the server.
    BinaryReader br = new BinaryReader(fs);
    dr["bytes"] = br.ReadBytes((int)br.BaseStream.Length);
    dt.Rows.Add(dr);
    // Send the file as attachment
    DataSet dsResult = ofg.Insert(24, ds);
    // The schema of the returning dataset can be extracted using the GetSchema call
    // with service type 25 (Return value). For this example we know that there are
    // two columns called sid (unique service id) and errorDescription.
    Console.WriteLine("Serial Id: " + (string)dsResult.Tables[0].Rows[0]["sid"]);
    Console.WriteLine("Error: " + (string)dsResult.Tables[0].Rows[0]["errorDescription"]);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


InsertXml Method

[image]

OfficeClip Web Services Documentation
Driver..::.InsertXml Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Inserts data into OfficeClip based on a service type. This call is same as the Insert call (that accepts a dataset as a parameter), the only difference is that this call accepts a serialized dataset. See description of the Insert call to find out which service items are accepted by this call.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public string InsertXml(
    int serviceType,
    string dataXml
)
Visual Basic (Declaration)
Public Function InsertXml ( _
    serviceType As Integer, _
    dataXml As String _
) As String
Visual C++
public:
String^ InsertXml(
    int serviceType,
    String^ dataXml
)

Parameters

serviceType
Type: System..::.Int32
An integer that represents the service type for which the schema is desired.
dataXml
Type: System..::.String
The Xml containing the data to be inserted. The data is serialization of the first table of the dataset.

Return Value

The output dataset. The schema of the dataset is the schema for the service type "Return Value".

See Also

Driver Class
OfficeClip.Service.Web Namespace


IsSessionExists Method

[image]

OfficeClip Web Services Documentation
Driver..::.IsSessionExists Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Checks whether the session exists. This function can be called periodically to make sure that the session has not timed out. If the session does not exists, most web service calls will fail unless the session is recreated.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public bool IsSessionExists()
Visual Basic (Declaration)
Public Function IsSessionExists As Boolean
Visual C++
public:
bool IsSessionExists()

Return Value

true if the session exists, false otherwise

Examples

CopyTest if the session exists
public static void IsSessionExists(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 try
 {
    bool exists = ofg.IsSessionExists();
    Console.WriteLine((exists) ? "Session Found" : "Session could not be found");
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


SessionOver Method

[image]

OfficeClip Web Services Documentation
Driver..::.SessionOver Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Destroys the session and effectively logs the user out.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public void SessionOver()
Visual Basic (Declaration)
Public Sub SessionOver
Visual C++
public:
void SessionOver()

Examples

CopyEnd the session to the Web Service
public static void EndConnection(
 WebServiceClient.Generic.OfficeClipGeneric ofg
 )
{
 try
 {
    ofg.SessionOver();
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}

See Also

Driver Class
OfficeClip.Service.Web Namespace


SetOrganization Method

[image]

OfficeClip Web Services Documentation
Driver..::.SetOrganization Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Changes the OfficeClip organization in the session. Succeeding calls are made to the new organization. Note that this does not change the organization in the regular OfficeClip login.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public bool SetOrganization(
    string sid
)
Visual Basic (Declaration)
Public Function SetOrganization ( _
    sid As String _
) As Boolean
Visual C++
public:
bool SetOrganization(
    String^ sid
)

Parameters

sid
Type: System..::.String
The serial id of the organization

Return Value

true if successful, false otherwise

See Also

Driver Class
OfficeClip.Service.Web Namespace


Update Method

[image]

OfficeClip Web Services Documentation
Driver..::.Update Method
Driver Class See Also

[This is preliminary documentation and is subject to change.]

Updates OfficeClip data using a key. Update returns a bool showing whether the update succeeded. Note that if a null value of any column is suppled, that column will not get updated in OfficeClip.
Entity(Id) | Description
Task(8) | The OfficeClip Task. The Service subtype for this type is the Contact(18) and Account(31)
Event(14) | The OfficeClip Calendar Events. The Service subtype for this type is the Contact(18) and Account(31)
Contact(18) | The contact management metaentity
Note(20) | The OfficeClip Notes Entity. The Service subtype for this type is the Contact(18) and Account(31)
Mail Merge Campaign Recipients(29) | The mail merge campaign recipient information, the serviceSubType should be sent as -1, the primaryKey is the campaignId
Attachment(24) | Document attachments with various applications
Mail Merge Campaign(28) | The mail merge campaign information
Timesheet(34) | Timesheet information, currently only the exported status of the timesheet can be set using this method
Expense(36) | Expense information. currently only the exported status of the expense can be set using this method

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public DataSet Update(
    int serviceType,
    DataSet ds
)
Visual Basic (Declaration)
Public Function Update ( _
    serviceType As Integer, _
    ds As DataSet _
) As DataSet
Visual C++
public:
DataSet^ Update(
    int serviceType,
    DataSet^ ds
)

Parameters

serviceType
Type: System..::.Int32
The unique service type
ds
Type: System.Data..::.DataSet
The dataset with the data to be updated

Return Value

The output dataset. The schema of the dataset is the schema for the service type "Return Value".

See Also

Driver Class
OfficeClip.Service.Web Namespace


ValidateUser Method

[image]

OfficeClip Web Services Documentation
Driver..::.ValidateUser Method
Driver Class Example See Also

[This is preliminary documentation and is subject to change.]

Validates the user and if the user gets validated, the session is created. If the validation is successful, the organization is set to the last organization that is opened in the OfficeClip user interface.

Namespace: OfficeClip.Service.Web
Assembly: OfficeClip.Service (in OfficeClip.Service)
Version: 8.1.1.0

Syntax

C#
public string ValidateUser(
    string emailAddress,
    string password
)
Visual Basic (Declaration)
Public Function ValidateUser ( _
    emailAddress As String, _
    password As String _
) As String
Visual C++
public:
String^ ValidateUser(
    String^ emailAddress,
    String^ password
)

Parameters

emailAddress
Type: System..::.String
The email address of the user
password
Type: System..::.String
The password of the user

Return Value

Empty string if the validation is successful, error if the validation fails.

Examples

CopyLogin to the Web Service
public static void Login(
 WebServiceClient.Generic.OfficeClipGeneric ofg, string emailAddress, string password
 )
{
 try
 {
    // try using the webservice to validate the user, if successful,
    // an user session will be created
     string msg = ofg.ValidateUser(emailAddress, password);
    if (msg == string.Empty)
     Console.WriteLine("Login Successful");
    else
     Console.WriteLine("Login Failed: " + msg);
 }
 catch (SoapException ex)
 {
    Console.WriteLine(ex.Message);
 }
}

See Also

Driver Class
OfficeClip.Service.Web Namespace