Skip to content

ZAF SDK v2 Feature Parity Status

Daniel Ribeiro edited this page Jul 15, 2016 · 14 revisions

Data APIs

High level

v1 API v2 API Available
this.comment() client.get('comment')
this.currentAccount() client.get('currentAccount')
this.currentUser() client.get('currentUser')
this.organization() client.get('organization')
this.requirement client.get('requirement:identifier')
this.ticket() client.get('ticket')
this.user() client.get('user')

Metadata and context

metadata and context represent the object returned by the SDK APIs with the corresponding names, i.e. client.metadata(). _Note: the metadata and context APIs are asynchronous and return a Promises/A+ conformant promise object, similar to get and set_​.

v1 API v2 API Available
this.guid() context.guid
this.id() metadata.appId
this.installationId() metadata.installationId
this.name() metadata.settings.name
this.version() metadata.version

Tickets

v1 API v2 API Available
ticket.assignee().group() client.get('ticket.assignee.group')
ticket.assignee().user() client.get('ticket.assignee.user')
ticket.assignee() client.get('ticket.assignee')
ticket.assignee({ groupId: value }) client.set('ticket.assignee', { groupId: value })
ticket.assignee({ userId: value1, groupId: value2 }) client.set('ticket.assignee', { userId: value1, groupId: value2 })
ticket.brand() client.get('ticket.brand')
ticket.brand({ id: value }) client.set('ticket.brand', { id: value })
ticket.collaborators().add({ email: value }) client.invoke('ticket.collaborators.add', { email: value })
ticket.collaborators().add({ id: value }) client.invoke('ticket.collaborators.add', { id: value })
ticket.collaborators().remove({ email: value }) client.invoke('ticket.collaborators.remove', { email: value })
ticket.collaborators().remove({ id: value }) client.invoke('ticket.collaborators.remove', { id: value })
ticket.collaborators() client.get('ticket.collaborators')
ticket.comment() client.get('ticket.comment')
ticket.comments() client.get('ticket.comments')
ticket.createdAt() client.get('ticket.createdAt')
ticket.customField(fieldName, value) client.set('ticket.customField:fieldName', value)
ticket.customField(fieldName) client.get('ticket.customField:fieldName')
ticket.description() client.get('ticket.description')
ticket.form() client.get('ticket.form')
ticket.id() client.get('ticket.id')
ticket.isNew() client.get('ticket.isNew')
ticket.open() TBD
ticket.organization() client.get('ticket.organization')
ticket.postSaveAction() client.get('ticket.postSaveAction')
ticket.priority() client.get('ticket.priority')
ticket.priority(value) client.set('ticket.priority', value)
ticket.requester() client.get('ticket.requester')
ticket.requester({ email: value1 [, name: value2] }) client.set('ticket.requester', { email: value1 [, name: value2] })
ticket.requester({ id: value }) client.set('ticket.requester', { id: value })
ticket.sharedWith() client.get('ticket.sharedWith')
ticket.sharedWith([ { id: value } ]) client.set('ticket.sharedWith', [ { id: value } ])
ticket.status() client.get('ticket.status')
ticket.status(value) client.set('ticket.status', value)
ticket.subject() client.get('ticket.subject')
ticket.subject(value) client.set('ticket.subject', value)
ticket.tags().add(value) client.invoke('ticket.tags.add', value)
ticket.tags().remove(value) client.invoke('ticket.tags.remove', value)
ticket.tags() client.get('ticket.tags')
ticket.tags([value1, value2...]) client.invoke('ticket.tags.add', [value1, value2...])
ticket.type() client.get('ticket.type')
ticket.type(value) client.set('ticket.type', value)
ticket.updatedAt() client.get('ticket.updatedAt')
ticket.viewers() client.get('ticket.viewers')

Comments

v1 API v2 API Available
comment.appendHtml(value) client.invoke('comment.appendHtml', value)
comment.appendMarkdown(value) client.invoke('comment.appendMarkdown', value)
comment.appendText(value) client.invoke('comment.appendText', value)
comment.attachments() client.get('comment.attachments')
comment.text() client.get('comment.text')
comment.text(value) client.set('comment.text', value)
comment.type() client.get('comment.type')
comment.type(value) client.set('comment.type', value)
comment.useRichText() client.get('comment.useRichText')

Attachments

v1 API V2 API Type Available
attachment.contentType() client.get('comment.attachments.0.contentType')
attachment.contentUrl() client.get('comment.attachments.0.contentUrl')
attachment.filename() client.get('comment.attachments.0.filename')
attachment.thumbnailUrl() client.get('comment.attachments.0.thumbnailUrl')
attachment.token() client.get('comment.attachments.0.token')

Groups

v1 API V2 API Type Available
group.id client.get('ticket.assignee.group.id')
group.name client.get('ticket.assignee.group.name')

Ticket Forms

v1 API V2 API Type Available
form.id(id) client.set('ticket.form.id', id)
form.id client.get('ticket.form.id')

Organization

v1 API v2 API Available
organization.customField(fieldName) client.get('organization.customField:fieldName')
organization.details() client.get('organization.details')
organization.details(value) client.set('organization.details', value)
organization.domains() client.get('organization.domains')
organization.domains(value) client.set('organization.domains', value)
organization.group() client.get('organization.group')
organization.id() client.get('organization.id')
organization.name() client.get('organization.name')
organization.notes() client.get('organization.notes')
organization.notes(value) client.set('organization.notes', value)
organization.sharedComments() client.get('organization.sharedComments')
organization.sharedTickets() client.get('organization.sharedTickets')
organization.tags() client.get('organization.tags')

Agreement

v1 API v2 API Available
agreement.id() client.get('ticket.sharedWith.0.id')
agreement.name() client.get('ticket.sharedWith.0.name')
agreement.partnerName() client.get('ticket.sharedWith.0.partnerName')

User

v1 API v2 API Available
user.alias() client.get('user.alias')
user.alias(value) client.get('user.alias', value)
user.avatarUrl() client.get('user.avatarUrl')
user.customField(fieldName) client.get('user.customField:fieldName')
user.details() client.get('user.details')
user.details(value) client.get('user.details', value)
user.email() client.get('user.email')
user.externalId() client.get('user.externalId')
user.externalId(value) client.set('user.externalId', value)
user.groups() client.get('user.groups')
user.id() client.get('user.id')
user.locale() client.get('user.locale')
user.name() client.get('user.name')
user.notes() client.get('user.notes')
user.notes(value) client.get('user.notes', value)
user.organizations() client.get('user.organizations')
user.role() client.get('user.role')
user.signature() client.get('user.signature')
user.signature(value) client.get('user.signature', value)
user.tags() client.get('user.tags')
user.timeZone() client.get('user.timeZone')

Collision user

v1 API v2 API Available
user.isEditing() client.get('ticket.viewers.0.isEditing')
user.isIdle() client.get('ticket.viewers.0.isIdle')

Account

v1 API v2 API Available
currentAccount.planName() client.get('currentAccount.planName')
currentAccount.subdomain() client.get('currentAccount.subdomain')
currentAccount.timeZone() client.get('currentAccount.timeZone')

###Brand

v1 API v2 API Available
brand.hasHelpCenter() client.get('ticket.brand.hasHelpCenter')
brand.id() client.get('ticket.brand.id')
brand.isActive() client.get('ticket.brand.isActive')
brand.isDefault() client.get('ticket.brand.isDefault')
brand.logo() client.get('ticket.brand.logo')
brand.name() client.get('ticket.brand.name')
brand.subdomain() client.get('ticket.brand.subdomain')
brand.url() client.get('ticket.brand.url')

Timezone

v1 API v2 API Available
timezone.formattedOffset() client.get('user.timezone.formattedOffset')
timezone.ianaName() client.get('user.timezone.ianaName')
timezone.name() client.get('user.timezone.name')
timezone.offset() client.get('user.timezone.offset')
timezone.translatedName() client.get('user.timezone.translatedName')

Interface APIs

High level

v1 API v2 API Available
this.$([selector]) Deprecated
this.assetURL(name) Deprecated
this.currentLocation() context.location
this.hide() client.invoke('app.hide')
this.organizationFields([fieldName]) client.get('organizationFields:fieldName')
this.renderTemplate(templateName, [data]) Deprecated
this.show() client.invoke('app.show')
this.switchTo(templateName, [data]) Deprecated
this.ticketFields([fieldName]) client.get('ticketFields:fieldName')
this.userFields([fieldName]) client.get('userFields:fieldName')
this.visible() client.get('app.visible')

Ticket Sidebar

v1 API v2 API Available
this.disableSave() client.invoke('disableSave')
this.enableSave() client.invoke('enableSave')
this.ticketFields(fieldName).options()[0] client.get('ticketFields:fieldName.options.0')
ticketField.disable() client.invoke('ticketFields:fieldName.disable')
ticketField.enable() client.invoke('ticketFields:fieldName.enable')
ticketField.hide() client.invoke('ticketFields:fieldName.hide')
ticketField.isEnabled() client.get('ticketFields:fieldName.isEnabled')
ticketField.isRequired() client.get('ticketFields:fieldName.isRequired')
ticketField.isVisible() client.get('ticketFields:fieldName.isVisible')
ticketField.label() client.get('ticketFields:fieldName.label')
ticketField.label(value) client.set('ticketFields:fieldName.label', value)
ticketField.name() client.get('ticketFields:fieldName.name')
ticketField.options() client.get('ticketFields:fieldName.options')
ticketField.show() client.invoke('ticketFields:fieldName.show')
ticketField.toggle() client.invoke('ticketFields:fieldName.toggle')
ticketFieldOption.disable() client.invoke('ticketFields:fieldName.options.0.disable')
ticketFieldOption.enable() client.invoke('ticketFields:fieldName.options.0.enable')
ticketFieldOption.hide() client.invoke('ticketFields:fieldName.options.0.hide')
ticketFieldOption.isEnabled() client.get('ticketFields:fieldName.options.0.isEnabled')
ticketFieldOption.isVisible() client.get('ticketFields:fieldName.options.0.isVisible')
ticketFieldOption.label() client.get('ticketFields:fieldName.options.0.label')
ticketFieldOption.label(value) client.set('ticketFields:fieldName.options.0.label', value)
ticketFieldOption.show() client.invoke('ticketFields:fieldName.options.0', 'show')
ticketFieldOption.toggle() client.invoke('ticketFields:fieldName.options.0', 'toggle')
ticketFieldOption.value() client.get('ticketFields:fieldName.options.0.value')

User profile

v1 API v2 API Available
userField.hide() client.invoke('userFields:fieldName.hide')
userField.isVisible() client.get('userFields:fieldName.isVisible')
userField.name() client.get('userFields:fieldName.name')
userField.options()[0] client.get('userFields:fieldName.options.0')
userField.show() client.invoke('userFields:fieldName', 'show')
userField.toggle() client.invoke('userFields:fieldName', 'toggle')
userFieldOption.label() client.get('userFields:fieldName.options.0.label')
userFieldOption.value() client.get('userFields:fieldName.options.0.value')

Organization profile

v1 API v2 API Available
organizationField.hide() client.invoke('organizationFields:fieldName.hide')
organizationField.isVisible() client.get('organizationFields:fieldName.isVisible')
organizationField.name() client.get('organizationFields:fieldName.name')
organizationField.options()[0] client.get('organizationFields:fieldName.options.0')
organizationField.show() client.invoke('organizationFields:fieldName.show')
organizationField.toggle() client.invoke('organizationFields:fieldName.toggle')
organizationFieldOption.label() client.get('organizationFields:fieldName.options.0.label')
organizationFieldOption.value() client.get('organizationFields:fieldName.options.0.value')

Navbar and Topbar

v1 API v2 API Available
this.popover('hide'); TBD
this.popover({ width: value, height: value }); TBD
this.preloadPane() TBD
this.setIconState(state, assetPath) TBD

Services

v1 API v2 API Available
services.newTicket() TBD
services.notify(message[, kind, duration]) client.invoke('notify', message[, kind, duration])
services.notify(message[, kind, options]) client.invoke('notify', message[, kind, options])
services.appsTray() client.get('appsTray')
services.appsTray().isVisible() client.get('appsTray.isVisible')
services.appsTray().hide() client.invoke('appsTray.hide')
services.appsTray().show() client.invoke('appsTray.show')

Events

Message events

v1 API v2 API Available
message.eventName TBD
this.message(name, [data], [locations]) TBD

Save hooks

v1 API v2 API Available
ticket.save TBD

Modals

v1 API v2 API Available
this.$('#myModal').modal(options) TBD

i18n

v1 API v2 API Available
this.I18n.t('translation.key') TBD
Clone this wiki locally