{"version":3,"sources":["node_modules/@vendasta/sales-v2/fesm2020/vendasta-sales-v2.mjs"],"sourcesContent":["import * as i0 from '@angular/core';\nimport { Injectable } from '@angular/core';\nimport { map, catchError, mapTo } from 'rxjs/operators';\nimport * as i1 from '@angular/common/http';\nimport { HttpHeaders } from '@angular/common/http';\nimport { throwError, of } from 'rxjs';\n\n// *********************************\n// Code generated by sdkgen\n// DO NOT EDIT!.\n//\n// Enums.\n// *********************************\nvar CancellationRequestReason = /*#__PURE__*/function (CancellationRequestReason) {\n CancellationRequestReason[CancellationRequestReason[\"CANCELLATION_REQUEST_REASON_UNSET\"] = 0] = \"CANCELLATION_REQUEST_REASON_UNSET\";\n CancellationRequestReason[CancellationRequestReason[\"CANCELLATION_REQUEST_REASON_OTHER\"] = 1] = \"CANCELLATION_REQUEST_REASON_OTHER\";\n return CancellationRequestReason;\n}(CancellationRequestReason || {});\nvar CancellationRequestStatus = /*#__PURE__*/function (CancellationRequestStatus) {\n CancellationRequestStatus[CancellationRequestStatus[\"CANCELLATION_REQUEST_STATUS_UNSET\"] = 0] = \"CANCELLATION_REQUEST_STATUS_UNSET\";\n CancellationRequestStatus[CancellationRequestStatus[\"CANCELLATION_REQUEST_STATUS_REQUESTED\"] = 1] = \"CANCELLATION_REQUEST_STATUS_REQUESTED\";\n CancellationRequestStatus[CancellationRequestStatus[\"CANCELLATION_REQUEST_STATUS_RESOLVED\"] = 2] = \"CANCELLATION_REQUEST_STATUS_RESOLVED\";\n CancellationRequestStatus[CancellationRequestStatus[\"CANCELLATION_REQUEST_STATUS_DECLINED\"] = 3] = \"CANCELLATION_REQUEST_STATUS_DECLINED\";\n return CancellationRequestStatus;\n}(CancellationRequestStatus || {});\n// *********************************\n// Code generated by sdkgen\n// DO NOT EDIT!.\n//\n// Enums.\n// *********************************\nvar AccountField = /*#__PURE__*/function (AccountField) {\n AccountField[AccountField[\"ACCOUNT_FIELD_CREATED\"] = 0] = \"ACCOUNT_FIELD_CREATED\";\n AccountField[AccountField[\"ACCOUNT_FIELD_UPDATED\"] = 1] = \"ACCOUNT_FIELD_UPDATED\";\n AccountField[AccountField[\"ACCOUNT_FIELD_NAME\"] = 2] = \"ACCOUNT_FIELD_NAME\";\n AccountField[AccountField[\"ACCOUNT_FIELD_CITY\"] = 3] = \"ACCOUNT_FIELD_CITY\";\n AccountField[AccountField[\"ACCOUNT_FIELD_STATE\"] = 4] = \"ACCOUNT_FIELD_STATE\";\n return AccountField;\n}(AccountField || {});\nvar AccountsArchived = /*#__PURE__*/function (AccountsArchived) {\n AccountsArchived[AccountsArchived[\"ACCOUNTS_ARCHIVED_INVALID\"] = 0] = \"ACCOUNTS_ARCHIVED_INVALID\";\n AccountsArchived[AccountsArchived[\"ACCOUNTS_ARCHIVED_ALL\"] = 1] = \"ACCOUNTS_ARCHIVED_ALL\";\n AccountsArchived[AccountsArchived[\"ACCOUNTS_ARCHIVED_TRUE\"] = 2] = \"ACCOUNTS_ARCHIVED_TRUE\";\n AccountsArchived[AccountsArchived[\"ACCOUNTS_ARCHIVED_FALSE\"] = 3] = \"ACCOUNTS_ARCHIVED_FALSE\";\n return AccountsArchived;\n}(AccountsArchived || {});\nvar SortDirection$1 = /*#__PURE__*/function (SortDirection) {\n SortDirection[SortDirection[\"SORT_DIRECTION_UNSET\"] = 0] = \"SORT_DIRECTION_UNSET\";\n SortDirection[SortDirection[\"SORT_DIRECTION_ASCENDING\"] = 1] = \"SORT_DIRECTION_ASCENDING\";\n SortDirection[SortDirection[\"SORT_DIRECTION_DESCENDING\"] = 2] = \"SORT_DIRECTION_DESCENDING\";\n return SortDirection;\n}(SortDirection$1 || {});\n// *********************************\n\nfunction enumStringToValue$7(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass FieldMask {\n static fromProto(proto) {\n let m = new FieldMask();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.paths !== 'undefined') {\n toReturn['paths'] = this.paths;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$6(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass Access {\n static fromProto(proto) {\n let m = new Access();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.scope !== 'undefined') {\n toReturn['scope'] = this.scope;\n }\n if (typeof this.public !== 'undefined') {\n toReturn['public'] = this.public;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$5(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass Salesperson {\n static fromProto(proto) {\n let m = new Salesperson();\n m = Object.assign(m, proto);\n if (proto.lastLogin) {\n m.lastLogin = new Date(proto.lastLogin);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.salespersonId !== 'undefined') {\n toReturn['salespersonId'] = this.salespersonId;\n }\n if (typeof this.firstName !== 'undefined') {\n toReturn['firstName'] = this.firstName;\n }\n if (typeof this.lastName !== 'undefined') {\n toReturn['lastName'] = this.lastName;\n }\n if (typeof this.email !== 'undefined') {\n toReturn['email'] = this.email;\n }\n if (typeof this.phoneNumber !== 'undefined') {\n toReturn['phoneNumber'] = this.phoneNumber;\n }\n if (typeof this.unifiedUserId !== 'undefined') {\n toReturn['unifiedUserId'] = this.unifiedUserId;\n }\n if (typeof this.countryCode !== 'undefined') {\n toReturn['countryCode'] = this.countryCode;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.photoUrlHttps !== 'undefined') {\n toReturn['photoUrlHttps'] = this.photoUrlHttps;\n }\n if (typeof this.lastLogin !== 'undefined' && this.lastLogin !== null) {\n toReturn['lastLogin'] = 'toApiJson' in this.lastLogin ? this.lastLogin.toApiJson() : this.lastLogin;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$4(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass Contact {\n static fromProto(proto) {\n let m = new Contact();\n m = Object.assign(m, proto);\n if (proto.created) {\n m.created = new Date(proto.created);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contactId !== 'undefined') {\n toReturn['contactId'] = this.contactId;\n }\n if (typeof this.notes !== 'undefined') {\n toReturn['notes'] = this.notes;\n }\n if (typeof this.firstName !== 'undefined') {\n toReturn['firstName'] = this.firstName;\n }\n if (typeof this.lastName !== 'undefined') {\n toReturn['lastName'] = this.lastName;\n }\n if (typeof this.title !== 'undefined') {\n toReturn['title'] = this.title;\n }\n if (typeof this.contactEmail !== 'undefined') {\n toReturn['contactEmail'] = this.contactEmail;\n }\n if (typeof this.phoneNumber !== 'undefined') {\n toReturn['phoneNumber'] = this.phoneNumber;\n }\n if (typeof this.phoneExtension !== 'undefined') {\n toReturn['phoneExtension'] = this.phoneExtension;\n }\n if (typeof this.accountIds !== 'undefined') {\n toReturn['accountIds'] = this.accountIds;\n }\n if (typeof this.created !== 'undefined' && this.created !== null) {\n toReturn['created'] = 'toApiJson' in this.created ? this.created.toApiJson() : this.created;\n }\n if (typeof this.phoneNumberCountry !== 'undefined') {\n toReturn['phoneNumberCountry'] = this.phoneNumberCountry;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$3(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass ActionList {\n static fromProto(proto) {\n let m = new ActionList();\n m = Object.assign(m, proto);\n if (proto.accounts) {\n m.accounts = parseInt(proto.accounts, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.id !== 'undefined') {\n toReturn['id'] = this.id;\n }\n if (typeof this.name !== 'undefined') {\n toReturn['name'] = this.name;\n }\n if (typeof this.accounts !== 'undefined') {\n toReturn['accounts'] = this.accounts;\n }\n if (typeof this.inProgress !== 'undefined') {\n toReturn['inProgress'] = this.inProgress;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$2(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass Business {\n static fromProto(proto) {\n let m = new Business();\n m = Object.assign(m, proto);\n if (proto.updated) {\n m.updated = new Date(proto.updated);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.id !== 'undefined') {\n toReturn['id'] = this.id;\n }\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.updated !== 'undefined' && this.updated !== null) {\n toReturn['updated'] = 'toApiJson' in this.updated ? this.updated.toApiJson() : this.updated;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue$1(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass CancellationRequest {\n static fromProto(proto) {\n let m = new CancellationRequest();\n m = Object.assign(m, proto);\n if (proto.status) {\n m.status = enumStringToValue$1(CancellationRequestStatus, proto.status);\n }\n if (proto.reason) {\n m.reason = enumStringToValue$1(CancellationRequestReason, proto.reason);\n }\n if (proto.requestCreatedDate) {\n m.requestCreatedDate = new Date(proto.requestCreatedDate);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.cancellationRequestId !== 'undefined') {\n toReturn['cancellationRequestId'] = this.cancellationRequestId;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.lineItemId !== 'undefined') {\n toReturn['lineItemId'] = this.lineItemId;\n }\n if (typeof this.requestingUserId !== 'undefined') {\n toReturn['requestingUserId'] = this.requestingUserId;\n }\n if (typeof this.status !== 'undefined') {\n toReturn['status'] = this.status;\n }\n if (typeof this.reason !== 'undefined') {\n toReturn['reason'] = this.reason;\n }\n if (typeof this.message !== 'undefined') {\n toReturn['message'] = this.message;\n }\n if (typeof this.requestCreatedDate !== 'undefined' && this.requestCreatedDate !== null) {\n toReturn['requestCreatedDate'] = 'toApiJson' in this.requestCreatedDate ? this.requestCreatedDate.toApiJson() : this.requestCreatedDate;\n }\n return toReturn;\n }\n}\nfunction enumStringToValue(enumRef, value) {\n if (typeof value === 'number') {\n return value;\n }\n return enumRef[value];\n}\nclass AccountLatestSalesActivity {\n static fromProto(proto) {\n let m = new AccountLatestSalesActivity();\n m = Object.assign(m, proto);\n if (proto.lastActivityDate) {\n m.lastActivityDate = new Date(proto.lastActivityDate);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountId !== 'undefined') {\n toReturn['accountId'] = this.accountId;\n }\n if (typeof this.lastActivityDate !== 'undefined' && this.lastActivityDate !== null) {\n toReturn['lastActivityDate'] = 'toApiJson' in this.lastActivityDate ? this.lastActivityDate.toApiJson() : this.lastActivityDate;\n }\n return toReturn;\n }\n}\nclass AddAccountsToActionListRequest {\n static fromProto(proto) {\n let m = new AddAccountsToActionListRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.listName !== 'undefined') {\n toReturn['listName'] = this.listName;\n }\n if (typeof this.accountGroupIds !== 'undefined') {\n toReturn['accountGroupIds'] = this.accountGroupIds;\n }\n return toReturn;\n }\n}\nclass AddAccountsToActionListResponse {\n static fromProto(proto) {\n let m = new AddAccountsToActionListResponse();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.actionListId !== 'undefined') {\n toReturn['actionListId'] = this.actionListId;\n }\n return toReturn;\n }\n}\nclass AddContactToCampaignRequest {\n static fromProto(proto) {\n let m = new AddContactToCampaignRequest();\n m = Object.assign(m, proto);\n if (proto.contact) {\n m.contact = AddContactToCampaignRequestRecipient.fromProto(proto.contact);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.campaignId !== 'undefined') {\n toReturn['campaignId'] = this.campaignId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.senderUnifiedUserId !== 'undefined') {\n toReturn['senderUnifiedUserId'] = this.senderUnifiedUserId;\n }\n if (typeof this.contact !== 'undefined' && this.contact !== null) {\n toReturn['contact'] = 'toApiJson' in this.contact ? this.contact.toApiJson() : this.contact;\n }\n return toReturn;\n }\n}\nclass CreateContactRequest {\n static fromProto(proto) {\n let m = new CreateContactRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.accountGroupIds !== 'undefined') {\n toReturn['accountGroupIds'] = this.accountGroupIds;\n }\n if (typeof this.phoneNumber !== 'undefined') {\n toReturn['phoneNumber'] = this.phoneNumber;\n }\n if (typeof this.phoneNumberCountry !== 'undefined') {\n toReturn['phoneNumberCountry'] = this.phoneNumberCountry;\n }\n if (typeof this.phoneNumberExtension !== 'undefined') {\n toReturn['phoneNumberExtension'] = this.phoneNumberExtension;\n }\n if (typeof this.email !== 'undefined') {\n toReturn['email'] = this.email;\n }\n if (typeof this.firstName !== 'undefined') {\n toReturn['firstName'] = this.firstName;\n }\n if (typeof this.lastName !== 'undefined') {\n toReturn['lastName'] = this.lastName;\n }\n if (typeof this.title !== 'undefined') {\n toReturn['title'] = this.title;\n }\n if (typeof this.notes !== 'undefined') {\n toReturn['notes'] = this.notes;\n }\n return toReturn;\n }\n}\nclass CreateContactResponse {\n static fromProto(proto) {\n let m = new CreateContactResponse();\n m = Object.assign(m, proto);\n if (proto.contact) {\n m.contact = Contact.fromProto(proto.contact);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contact !== 'undefined' && this.contact !== null) {\n toReturn['contact'] = 'toApiJson' in this.contact ? this.contact.toApiJson() : this.contact;\n }\n return toReturn;\n }\n}\nclass CreateRequest {\n static fromProto(proto) {\n let m = new CreateRequest();\n m = Object.assign(m, proto);\n if (proto.status) {\n m.status = enumStringToValue(CancellationRequestStatus, proto.status);\n }\n if (proto.reason) {\n m.reason = enumStringToValue(CancellationRequestReason, proto.reason);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.lineItemId !== 'undefined') {\n toReturn['lineItemId'] = this.lineItemId;\n }\n if (typeof this.requestingUserId !== 'undefined') {\n toReturn['requestingUserId'] = this.requestingUserId;\n }\n if (typeof this.status !== 'undefined') {\n toReturn['status'] = this.status;\n }\n if (typeof this.reason !== 'undefined') {\n toReturn['reason'] = this.reason;\n }\n if (typeof this.message !== 'undefined') {\n toReturn['message'] = this.message;\n }\n return toReturn;\n }\n}\nclass CreateSalespersonForUserRequest {\n static fromProto(proto) {\n let m = new CreateSalespersonForUserRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.authCheckOnly !== 'undefined') {\n toReturn['authCheckOnly'] = this.authCheckOnly;\n }\n if (typeof this.userId !== 'undefined') {\n toReturn['userId'] = this.userId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.isSalesManager !== 'undefined') {\n toReturn['isSalesManager'] = this.isSalesManager;\n }\n return toReturn;\n }\n}\nclass CreateSalespersonForUserResponse {\n static fromProto(proto) {\n let m = new CreateSalespersonForUserResponse();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n return toReturn;\n }\n}\nclass DateRangeFilter {\n static fromProto(proto) {\n let m = new DateRangeFilter();\n m = Object.assign(m, proto);\n if (proto.beginRange) {\n m.beginRange = new Date(proto.beginRange);\n }\n if (proto.endRange) {\n m.endRange = new Date(proto.endRange);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.beginRange !== 'undefined' && this.beginRange !== null) {\n toReturn['beginRange'] = 'toApiJson' in this.beginRange ? this.beginRange.toApiJson() : this.beginRange;\n }\n if (typeof this.endRange !== 'undefined' && this.endRange !== null) {\n toReturn['endRange'] = 'toApiJson' in this.endRange ? this.endRange.toApiJson() : this.endRange;\n }\n return toReturn;\n }\n}\nclass DeleteContactRequest {\n static fromProto(proto) {\n let m = new DeleteContactRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.contactId !== 'undefined') {\n toReturn['contactId'] = this.contactId;\n }\n return toReturn;\n }\n}\nclass EffortAggregate {\n static fromProto(proto) {\n let m = new EffortAggregate();\n m = Object.assign(m, proto);\n if (proto.efforts) {\n m.efforts = Object.keys(proto.efforts).reduce((obj, k) => {\n obj[k] = parseInt(proto.efforts[k], 10);\n return obj;\n }, {});\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.efforts !== 'undefined' && this.efforts !== null) {\n toReturn['efforts'] = 'toApiJson' in this.efforts ? this.efforts.toApiJson() : this.efforts;\n }\n return toReturn;\n }\n}\nclass EffortAggregateEffortsEntry {\n static fromProto(proto) {\n let m = new EffortAggregateEffortsEntry();\n m = Object.assign(m, proto);\n if (proto.value) {\n m.value = parseInt(proto.value, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.key !== 'undefined') {\n toReturn['key'] = this.key;\n }\n if (typeof this.value !== 'undefined') {\n toReturn['value'] = this.value;\n }\n return toReturn;\n }\n}\nclass GetAccountPrimaryContactRequest {\n static fromProto(proto) {\n let m = new GetAccountPrimaryContactRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountId !== 'undefined') {\n toReturn['accountId'] = this.accountId;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n return toReturn;\n }\n}\nclass GetAccountPrimaryContactResponse {\n static fromProto(proto) {\n let m = new GetAccountPrimaryContactResponse();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contactId !== 'undefined') {\n toReturn['contactId'] = this.contactId;\n }\n return toReturn;\n }\n}\nclass GetContactByIDRequest {\n static fromProto(proto) {\n let m = new GetContactByIDRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contactId !== 'undefined') {\n toReturn['contactId'] = this.contactId;\n }\n return toReturn;\n }\n}\nclass GetContactResponse {\n static fromProto(proto) {\n let m = new GetContactResponse();\n m = Object.assign(m, proto);\n if (proto.contact) {\n m.contact = Contact.fromProto(proto.contact);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contact !== 'undefined' && this.contact !== null) {\n toReturn['contact'] = 'toApiJson' in this.contact ? this.contact.toApiJson() : this.contact;\n }\n return toReturn;\n }\n}\nclass GetContactsForAccountsRequest {\n static fromProto(proto) {\n let m = new GetContactsForAccountsRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.accountIds !== 'undefined') {\n toReturn['accountIds'] = this.accountIds;\n }\n return toReturn;\n }\n}\nclass GetContactsForAccountsResponse {\n static fromProto(proto) {\n let m = new GetContactsForAccountsResponse();\n m = Object.assign(m, proto);\n if (proto.contacts) {\n m.contacts = proto.contacts.map(Contact.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contacts !== 'undefined' && this.contacts !== null) {\n toReturn['contacts'] = 'toApiJson' in this.contacts ? this.contacts.toApiJson() : this.contacts;\n }\n return toReturn;\n }\n}\nclass GetMultiCampaignsRequest {\n static fromProto(proto) {\n let m = new GetMultiCampaignsRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.campaignIds !== 'undefined') {\n toReturn['campaignIds'] = this.campaignIds;\n }\n return toReturn;\n }\n}\nclass GetMultiCampaignsResponse {\n static fromProto(proto) {\n let m = new GetMultiCampaignsResponse();\n m = Object.assign(m, proto);\n if (proto.campaigns) {\n m.campaigns = proto.campaigns.map(SalesCampaign.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.campaigns !== 'undefined' && this.campaigns !== null) {\n toReturn['campaigns'] = 'toApiJson' in this.campaigns ? this.campaigns.toApiJson() : this.campaigns;\n }\n return toReturn;\n }\n}\nclass GetMultiOpportunityEffortsRequest {\n static fromProto(proto) {\n let m = new GetMultiOpportunityEffortsRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.opportunityIds !== 'undefined') {\n toReturn['opportunityIds'] = this.opportunityIds;\n }\n return toReturn;\n }\n}\nclass GetMultiOpportunityEffortsResponse {\n static fromProto(proto) {\n let m = new GetMultiOpportunityEffortsResponse();\n m = Object.assign(m, proto);\n if (proto.opportunityEfforts) {\n m.opportunityEfforts = Object.keys(proto.opportunityEfforts).reduce((obj, k) => {\n obj[k] = EffortAggregate.fromProto(proto.opportunityEfforts[k]);\n return obj;\n }, {});\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.opportunityEfforts !== 'undefined' && this.opportunityEfforts !== null) {\n toReturn['opportunityEfforts'] = 'toApiJson' in this.opportunityEfforts ? this.opportunityEfforts.toApiJson() : this.opportunityEfforts;\n }\n return toReturn;\n }\n}\nclass GetSalesActivityForAccountsRequest {\n static fromProto(proto) {\n let m = new GetSalesActivityForAccountsRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.accountIds !== 'undefined') {\n toReturn['accountIds'] = this.accountIds;\n }\n return toReturn;\n }\n}\nclass GetSalesActivityForAccountsResponse {\n static fromProto(proto) {\n let m = new GetSalesActivityForAccountsResponse();\n m = Object.assign(m, proto);\n if (proto.accountsLatestSalesActivity) {\n m.accountsLatestSalesActivity = proto.accountsLatestSalesActivity.map(AccountLatestSalesActivity.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountsLatestSalesActivity !== 'undefined' && this.accountsLatestSalesActivity !== null) {\n toReturn['accountsLatestSalesActivity'] = 'toApiJson' in this.accountsLatestSalesActivity ? this.accountsLatestSalesActivity.toApiJson() : this.accountsLatestSalesActivity;\n }\n return toReturn;\n }\n}\nclass GetSalespersonByEmailRequest {\n static fromProto(proto) {\n let m = new GetSalespersonByEmailRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.email !== 'undefined') {\n toReturn['email'] = this.email;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n return toReturn;\n }\n}\nclass GetSalespersonByEmailResponse {\n static fromProto(proto) {\n let m = new GetSalespersonByEmailResponse();\n m = Object.assign(m, proto);\n if (proto.salesperson) {\n m.salesperson = Salesperson.fromProto(proto.salesperson);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.salesperson !== 'undefined' && this.salesperson !== null) {\n toReturn['salesperson'] = 'toApiJson' in this.salesperson ? this.salesperson.toApiJson() : this.salesperson;\n }\n return toReturn;\n }\n}\nclass IsConfigValidRequest {\n static fromProto(proto) {\n let m = new IsConfigValidRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n return toReturn;\n }\n}\nclass IsConfigValidResponse {\n static fromProto(proto) {\n let m = new IsConfigValidResponse();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.isValid !== 'undefined') {\n toReturn['isValid'] = this.isValid;\n }\n return toReturn;\n }\n}\nclass ListActionListsRequest {\n static fromProto(proto) {\n let m = new ListActionListsRequest();\n m = Object.assign(m, proto);\n if (proto.pagingOptions) {\n m.pagingOptions = PageIndexedRequestOptions.fromProto(proto.pagingOptions);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {\n toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.searchString !== 'undefined') {\n toReturn['searchString'] = this.searchString;\n }\n return toReturn;\n }\n}\nclass ListActionListsResponse {\n static fromProto(proto) {\n let m = new ListActionListsResponse();\n m = Object.assign(m, proto);\n if (proto.actionLists) {\n m.actionLists = proto.actionLists.map(ActionList.fromProto);\n }\n if (proto.nextPage) {\n m.nextPage = parseInt(proto.nextPage, 10);\n }\n if (proto.totalActionListsCount) {\n m.totalActionListsCount = parseInt(proto.totalActionListsCount, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.actionLists !== 'undefined' && this.actionLists !== null) {\n toReturn['actionLists'] = 'toApiJson' in this.actionLists ? this.actionLists.toApiJson() : this.actionLists;\n }\n if (typeof this.nextPage !== 'undefined') {\n toReturn['nextPage'] = this.nextPage;\n }\n if (typeof this.totalActionListsCount !== 'undefined') {\n toReturn['totalActionListsCount'] = this.totalActionListsCount;\n }\n return toReturn;\n }\n}\nclass ListContactsForBusinessRequest {\n static fromProto(proto) {\n let m = new ListContactsForBusinessRequest();\n m = Object.assign(m, proto);\n if (proto.fieldMask) {\n m.fieldMask = FieldMask.fromProto(proto.fieldMask);\n }\n if (proto.pagingOptions) {\n m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.fieldMask !== 'undefined' && this.fieldMask !== null) {\n toReturn['fieldMask'] = 'toApiJson' in this.fieldMask ? this.fieldMask.toApiJson() : this.fieldMask;\n }\n if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {\n toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;\n }\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n return toReturn;\n }\n}\nclass ListContactsForBusinessResponse {\n static fromProto(proto) {\n let m = new ListContactsForBusinessResponse();\n m = Object.assign(m, proto);\n if (proto.contacts) {\n m.contacts = proto.contacts.map(Contact.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contacts !== 'undefined' && this.contacts !== null) {\n toReturn['contacts'] = 'toApiJson' in this.contacts ? this.contacts.toApiJson() : this.contacts;\n }\n return toReturn;\n }\n}\nclass ListContactsForEmailRequest {\n static fromProto(proto) {\n let m = new ListContactsForEmailRequest();\n m = Object.assign(m, proto);\n if (proto.fieldMask) {\n m.fieldMask = FieldMask.fromProto(proto.fieldMask);\n }\n if (proto.pagingOptions) {\n m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.fieldMask !== 'undefined' && this.fieldMask !== null) {\n toReturn['fieldMask'] = 'toApiJson' in this.fieldMask ? this.fieldMask.toApiJson() : this.fieldMask;\n }\n if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {\n toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.contactEmail !== 'undefined') {\n toReturn['contactEmail'] = this.contactEmail;\n }\n return toReturn;\n }\n}\nclass ListContactsResponse {\n static fromProto(proto) {\n let m = new ListContactsResponse();\n m = Object.assign(m, proto);\n if (proto.contacts) {\n m.contacts = proto.contacts.map(Contact.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.contacts !== 'undefined' && this.contacts !== null) {\n toReturn['contacts'] = 'toApiJson' in this.contacts ? this.contacts.toApiJson() : this.contacts;\n }\n return toReturn;\n }\n}\nclass ListRequest {\n static fromProto(proto) {\n let m = new ListRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n return toReturn;\n }\n}\nclass ListResponse {\n static fromProto(proto) {\n let m = new ListResponse();\n m = Object.assign(m, proto);\n if (proto.requests) {\n m.requests = proto.requests.map(CancellationRequest.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.requests !== 'undefined' && this.requests !== null) {\n toReturn['requests'] = 'toApiJson' in this.requests ? this.requests.toApiJson() : this.requests;\n }\n return toReturn;\n }\n}\nclass LookupCampaignsRequest {\n static fromProto(proto) {\n let m = new LookupCampaignsRequest();\n m = Object.assign(m, proto);\n if (proto.offset) {\n m.offset = parseInt(proto.offset, 10);\n }\n if (proto.pageSize) {\n m.pageSize = parseInt(proto.pageSize, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.status !== 'undefined') {\n toReturn['status'] = this.status;\n }\n if (typeof this.focus !== 'undefined') {\n toReturn['focus'] = this.focus;\n }\n if (typeof this.state !== 'undefined') {\n toReturn['state'] = this.state;\n }\n if (typeof this.offset !== 'undefined') {\n toReturn['offset'] = this.offset;\n }\n if (typeof this.pageSize !== 'undefined') {\n toReturn['pageSize'] = this.pageSize;\n }\n if (typeof this.searchTerm !== 'undefined') {\n toReturn['searchTerm'] = this.searchTerm;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n return toReturn;\n }\n}\nclass LookupCampaignsResponse {\n static fromProto(proto) {\n let m = new LookupCampaignsResponse();\n m = Object.assign(m, proto);\n if (proto.campaigns) {\n m.campaigns = proto.campaigns.map(SalesCampaign.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.campaigns !== 'undefined' && this.campaigns !== null) {\n toReturn['campaigns'] = 'toApiJson' in this.campaigns ? this.campaigns.toApiJson() : this.campaigns;\n }\n return toReturn;\n }\n}\nclass GetMultiOpportunityEffortsResponseOpportunityEffortsEntry {\n static fromProto(proto) {\n let m = new GetMultiOpportunityEffortsResponseOpportunityEffortsEntry();\n m = Object.assign(m, proto);\n if (proto.value) {\n m.value = EffortAggregate.fromProto(proto.value);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.key !== 'undefined') {\n toReturn['key'] = this.key;\n }\n if (typeof this.value !== 'undefined' && this.value !== null) {\n toReturn['value'] = 'toApiJson' in this.value ? this.value.toApiJson() : this.value;\n }\n return toReturn;\n }\n}\nclass PageIndexedRequestOptions {\n static fromProto(proto) {\n let m = new PageIndexedRequestOptions();\n m = Object.assign(m, proto);\n if (proto.pageSize) {\n m.pageSize = parseInt(proto.pageSize, 10);\n }\n if (proto.pageIndex) {\n m.pageIndex = parseInt(proto.pageIndex, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.pageSize !== 'undefined') {\n toReturn['pageSize'] = this.pageSize;\n }\n if (typeof this.pageIndex !== 'undefined') {\n toReturn['pageIndex'] = this.pageIndex;\n }\n return toReturn;\n }\n}\nclass PagedRequestOptions {\n static fromProto(proto) {\n let m = new PagedRequestOptions();\n m = Object.assign(m, proto);\n if (proto.pageSize) {\n m.pageSize = parseInt(proto.pageSize, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.pageSize !== 'undefined') {\n toReturn['pageSize'] = this.pageSize;\n }\n return toReturn;\n }\n}\nclass AddContactToCampaignRequestRecipient {\n static fromProto(proto) {\n let m = new AddContactToCampaignRequestRecipient();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountGroupId !== 'undefined') {\n toReturn['accountGroupId'] = this.accountGroupId;\n }\n if (typeof this.emailAddress !== 'undefined') {\n toReturn['emailAddress'] = this.emailAddress;\n }\n return toReturn;\n }\n}\nclass ResendUserWelcomeEmailRequest {\n static fromProto(proto) {\n let m = new ResendUserWelcomeEmailRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.subjectId !== 'undefined') {\n toReturn['subjectId'] = this.subjectId;\n }\n return toReturn;\n }\n}\nclass ResendUserWelcomeEmailResponse {\n static fromProto(proto) {\n let m = new ResendUserWelcomeEmailResponse();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.notificationId !== 'undefined') {\n toReturn['notificationId'] = this.notificationId;\n }\n return toReturn;\n }\n}\nclass SalesCampaign {\n static fromProto(proto) {\n let m = new SalesCampaign();\n m = Object.assign(m, proto);\n if (proto.campaignSchedule) {\n m.campaignSchedule = proto.campaignSchedule.map(ScheduleStep.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.name !== 'undefined') {\n toReturn['name'] = this.name;\n }\n if (typeof this.campaignStatus !== 'undefined') {\n toReturn['campaignStatus'] = this.campaignStatus;\n }\n if (typeof this.campaignId !== 'undefined') {\n toReturn['campaignId'] = this.campaignId;\n }\n if (typeof this.campaignSchedule !== 'undefined' && this.campaignSchedule !== null) {\n toReturn['campaignSchedule'] = 'toApiJson' in this.campaignSchedule ? this.campaignSchedule.toApiJson() : this.campaignSchedule;\n }\n return toReturn;\n }\n}\nclass ScheduleStep {\n static fromProto(proto) {\n let m = new ScheduleStep();\n m = Object.assign(m, proto);\n if (proto.secondsAfterLastEmail) {\n m.secondsAfterLastEmail = parseInt(proto.secondsAfterLastEmail, 10);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.stepType !== 'undefined') {\n toReturn['stepType'] = this.stepType;\n }\n if (typeof this.secondsAfterLastEmail !== 'undefined') {\n toReturn['secondsAfterLastEmail'] = this.secondsAfterLastEmail;\n }\n if (typeof this.name !== 'undefined') {\n toReturn['name'] = this.name;\n }\n if (typeof this.templateId !== 'undefined') {\n toReturn['templateId'] = this.templateId;\n }\n return toReturn;\n }\n}\nclass SearchBusinessesByContactEmailRequest {\n static fromProto(proto) {\n let m = new SearchBusinessesByContactEmailRequest();\n m = Object.assign(m, proto);\n if (proto.fieldMask) {\n m.fieldMask = FieldMask.fromProto(proto.fieldMask);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.fieldMask !== 'undefined' && this.fieldMask !== null) {\n toReturn['fieldMask'] = 'toApiJson' in this.fieldMask ? this.fieldMask.toApiJson() : this.fieldMask;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.contactEmailQuery !== 'undefined') {\n toReturn['contactEmailQuery'] = this.contactEmailQuery;\n }\n if (typeof this.assignedUserId !== 'undefined') {\n toReturn['assignedUserId'] = this.assignedUserId;\n }\n return toReturn;\n }\n}\nclass SearchRequest {\n static fromProto(proto) {\n let m = new SearchRequest();\n m = Object.assign(m, proto);\n if (proto.fieldMask) {\n m.fieldMask = FieldMask.fromProto(proto.fieldMask);\n }\n if (proto.pagingOptions) {\n m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.fieldMask !== 'undefined' && this.fieldMask !== null) {\n toReturn['fieldMask'] = 'toApiJson' in this.fieldMask ? this.fieldMask.toApiJson() : this.fieldMask;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {\n toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;\n }\n return toReturn;\n }\n}\nclass SearchResponse {\n static fromProto(proto) {\n let m = new SearchResponse();\n m = Object.assign(m, proto);\n if (proto.businesses) {\n m.businesses = proto.businesses.map(Business.fromProto);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.businesses !== 'undefined' && this.businesses !== null) {\n toReturn['businesses'] = 'toApiJson' in this.businesses ? this.businesses.toApiJson() : this.businesses;\n }\n return toReturn;\n }\n}\nclass SendPasswordResetEmailRequest {\n static fromProto(proto) {\n let m = new SendPasswordResetEmailRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.salesPersonId !== 'undefined') {\n toReturn['salesPersonId'] = this.salesPersonId;\n }\n if (typeof this.usePlatformDefaultDomain !== 'undefined') {\n toReturn['usePlatformDefaultDomain'] = this.usePlatformDefaultDomain;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n return toReturn;\n }\n}\nclass SetAccountPrimaryContactRequest {\n static fromProto(proto) {\n let m = new SetAccountPrimaryContactRequest();\n m = Object.assign(m, proto);\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.accountId !== 'undefined') {\n toReturn['accountId'] = this.accountId;\n }\n if (typeof this.contactId !== 'undefined') {\n toReturn['contactId'] = this.contactId;\n }\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n return toReturn;\n }\n}\nclass UpdateContactRequest {\n static fromProto(proto) {\n let m = new UpdateContactRequest();\n m = Object.assign(m, proto);\n if (proto.contact) {\n m.contact = Contact.fromProto(proto.contact);\n }\n if (proto.mutatorMask) {\n m.mutatorMask = FieldMask.fromProto(proto.mutatorMask);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.partnerId !== 'undefined') {\n toReturn['partnerId'] = this.partnerId;\n }\n if (typeof this.marketId !== 'undefined') {\n toReturn['marketId'] = this.marketId;\n }\n if (typeof this.contact !== 'undefined' && this.contact !== null) {\n toReturn['contact'] = 'toApiJson' in this.contact ? this.contact.toApiJson() : this.contact;\n }\n if (typeof this.mutatorMask !== 'undefined' && this.mutatorMask !== null) {\n toReturn['mutatorMask'] = 'toApiJson' in this.mutatorMask ? this.mutatorMask.toApiJson() : this.mutatorMask;\n }\n return toReturn;\n }\n}\nclass UpdateStatusRequest {\n static fromProto(proto) {\n let m = new UpdateStatusRequest();\n m = Object.assign(m, proto);\n if (proto.status) {\n m.status = enumStringToValue(CancellationRequestStatus, proto.status);\n }\n return m;\n }\n constructor(kwargs) {\n if (!kwargs) {\n return;\n }\n Object.assign(this, kwargs);\n }\n toApiJson() {\n const toReturn = {};\n if (typeof this.cancellationRequestId !== 'undefined') {\n toReturn['cancellationRequestId'] = this.cancellationRequestId;\n }\n if (typeof this.status !== 'undefined') {\n toReturn['status'] = this.status;\n }\n if (typeof this.userId !== 'undefined') {\n toReturn['userId'] = this.userId;\n }\n return toReturn;\n }\n}\n\n// *********************************\n\nconst environment = (window ? window['environment'] : 'prod') ?? 'prod';\nconst hostMap = {\n 'local': '',\n 'test': '',\n 'demo': 'sales-api-demo.vendasta-internal.com',\n 'prod': 'sales-api-prod.vendasta-internal.com',\n 'production': 'sales-api-prod.vendasta-internal.com'\n};\nlet HostService = /*#__PURE__*/(() => {\n class HostService {\n get host() {\n return hostMap[environment.toLowerCase()];\n }\n get hostWithScheme() {\n return 'https://' + this.host;\n }\n }\n HostService.ɵfac = function HostService_Factory(t) {\n return new (t || HostService)();\n };\n HostService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HostService,\n factory: HostService.ɵfac,\n providedIn: 'root'\n });\n return HostService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet ActionListsApiService = /*#__PURE__*/(() => {\n class ActionListsApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n listActionLists(r) {\n const request = r.toApiJson ? r : new ListActionListsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.ActionLists/ListActionLists\", request.toApiJson(), this.apiOptions()).pipe(map(resp => ListActionListsResponse.fromProto(resp)));\n }\n addAccountsToActionList(r) {\n const request = r.toApiJson ? r : new AddAccountsToActionListRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.ActionLists/AddAccountsToActionList\", request.toApiJson(), this.apiOptions()).pipe(map(resp => AddAccountsToActionListResponse.fromProto(resp)));\n }\n }\n ActionListsApiService.ɵfac = function ActionListsApiService_Factory(t) {\n return new (t || ActionListsApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n ActionListsApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ActionListsApiService,\n factory: ActionListsApiService.ɵfac,\n providedIn: 'root'\n });\n return ActionListsApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet BusinessApiService = /*#__PURE__*/(() => {\n class BusinessApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n search(r) {\n const request = r.toApiJson ? r : new SearchRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.BusinessService/Search\", request.toApiJson(), this.apiOptions()).pipe(map(resp => SearchResponse.fromProto(resp)));\n }\n searchBusinessesByContactEmail(r) {\n const request = r.toApiJson ? r : new SearchBusinessesByContactEmailRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.BusinessService/SearchBusinessesByContactEmail\", request.toApiJson(), this.apiOptions()).pipe(map(resp => SearchResponse.fromProto(resp)));\n }\n setAccountPrimaryContact(r) {\n const request = r.toApiJson ? r : new SetAccountPrimaryContactRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.BusinessService/SetAccountPrimaryContact\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n getAccountPrimaryContact(r) {\n const request = r.toApiJson ? r : new GetAccountPrimaryContactRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.BusinessService/GetAccountPrimaryContact\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetAccountPrimaryContactResponse.fromProto(resp)));\n }\n getSalesActivityForAccounts(r) {\n const request = r.toApiJson ? r : new GetSalesActivityForAccountsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.BusinessService/GetSalesActivityForAccounts\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetSalesActivityForAccountsResponse.fromProto(resp)));\n }\n }\n BusinessApiService.ɵfac = function BusinessApiService_Factory(t) {\n return new (t || BusinessApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n BusinessApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: BusinessApiService,\n factory: BusinessApiService.ɵfac,\n providedIn: 'root'\n });\n return BusinessApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet CampaignApiService = /*#__PURE__*/(() => {\n class CampaignApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n getMultiCampaigns(r) {\n const request = r.toApiJson ? r : new GetMultiCampaignsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CampaignService/GetMultiCampaigns\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetMultiCampaignsResponse.fromProto(resp)));\n }\n lookupCampaigns(r) {\n const request = r.toApiJson ? r : new LookupCampaignsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CampaignService/LookupCampaigns\", request.toApiJson(), this.apiOptions()).pipe(map(resp => LookupCampaignsResponse.fromProto(resp)));\n }\n addContactToCampaign(r) {\n const request = r.toApiJson ? r : new AddContactToCampaignRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CampaignService/AddContactToCampaign\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n }\n CampaignApiService.ɵfac = function CampaignApiService_Factory(t) {\n return new (t || CampaignApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n CampaignApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: CampaignApiService,\n factory: CampaignApiService.ɵfac,\n providedIn: 'root'\n });\n return CampaignApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet CancellationRequestsApiService = /*#__PURE__*/(() => {\n class CancellationRequestsApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n list(r) {\n const request = r.toApiJson ? r : new ListRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CancellationRequests/List\", request.toApiJson(), this.apiOptions()).pipe(map(resp => ListResponse.fromProto(resp)));\n }\n updateStatus(r) {\n const request = r.toApiJson ? r : new UpdateStatusRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CancellationRequests/UpdateStatus\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n create(r) {\n const request = r.toApiJson ? r : new CreateRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CancellationRequests/Create\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n isConfigValid(r) {\n const request = r.toApiJson ? r : new IsConfigValidRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.CancellationRequests/IsConfigValid\", request.toApiJson(), this.apiOptions()).pipe(map(resp => IsConfigValidResponse.fromProto(resp)));\n }\n }\n CancellationRequestsApiService.ɵfac = function CancellationRequestsApiService_Factory(t) {\n return new (t || CancellationRequestsApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n CancellationRequestsApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: CancellationRequestsApiService,\n factory: CancellationRequestsApiService.ɵfac,\n providedIn: 'root'\n });\n return CancellationRequestsApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet ContactsApiService = /*#__PURE__*/(() => {\n class ContactsApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n getContactById(r) {\n const request = r.toApiJson ? r : new GetContactByIDRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/GetContactByID\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetContactResponse.fromProto(resp)));\n }\n listContactsForEmail(r) {\n const request = r.toApiJson ? r : new ListContactsForEmailRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/ListContactsForEmail\", request.toApiJson(), this.apiOptions()).pipe(map(resp => ListContactsResponse.fromProto(resp)));\n }\n listContactsForBusiness(r) {\n const request = r.toApiJson ? r : new ListContactsForBusinessRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/ListContactsForBusiness\", request.toApiJson(), this.apiOptions()).pipe(map(resp => ListContactsForBusinessResponse.fromProto(resp)));\n }\n resendUserWelcomeEmail(r) {\n const request = r.toApiJson ? r : new ResendUserWelcomeEmailRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/ResendUserWelcomeEmail\", request.toApiJson(), this.apiOptions()).pipe(map(resp => ResendUserWelcomeEmailResponse.fromProto(resp)));\n }\n getContactsForAccounts(r) {\n const request = r.toApiJson ? r : new GetContactsForAccountsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/GetContactsForAccounts\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetContactsForAccountsResponse.fromProto(resp)));\n }\n update(r) {\n const request = r.toApiJson ? r : new UpdateContactRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/Update\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n delete(r) {\n const request = r.toApiJson ? r : new DeleteContactRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/Delete\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n create(r) {\n const request = r.toApiJson ? r : new CreateContactRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Contacts/Create\", request.toApiJson(), this.apiOptions()).pipe(map(resp => CreateContactResponse.fromProto(resp)));\n }\n }\n ContactsApiService.ɵfac = function ContactsApiService_Factory(t) {\n return new (t || ContactsApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n ContactsApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ContactsApiService,\n factory: ContactsApiService.ɵfac,\n providedIn: 'root'\n });\n return ContactsApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet SalespeopleApiService = /*#__PURE__*/(() => {\n class SalespeopleApiService {\n constructor(http, hostService) {\n this.http = http;\n this.hostService = hostService;\n this._host = this.hostService.hostWithScheme;\n }\n apiOptions() {\n return {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n }),\n withCredentials: true\n };\n }\n getSalespersonByEmail(r) {\n const request = r.toApiJson ? r : new GetSalespersonByEmailRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Salespeople/GetSalespersonByEmail\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetSalespersonByEmailResponse.fromProto(resp)));\n }\n createSalespersonForUser(r) {\n const request = r.toApiJson ? r : new CreateSalespersonForUserRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Salespeople/CreateSalespersonForUser\", request.toApiJson(), this.apiOptions()).pipe(map(resp => CreateSalespersonForUserResponse.fromProto(resp)));\n }\n getMultiOpportunityEfforts(r) {\n const request = r.toApiJson ? r : new GetMultiOpportunityEffortsRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Salespeople/GetMultiOpportunityEfforts\", request.toApiJson(), this.apiOptions()).pipe(map(resp => GetMultiOpportunityEffortsResponse.fromProto(resp)));\n }\n sendPasswordResetEmail(r) {\n const request = r.toApiJson ? r : new SendPasswordResetEmailRequest(r);\n return this.http.post(this._host + \"/sales.v2beta1.Salespeople/SendPasswordResetEmail\", request.toApiJson(), {\n ...this.apiOptions(),\n observe: 'response'\n });\n }\n }\n SalespeopleApiService.ɵfac = function SalespeopleApiService_Factory(t) {\n return new (t || SalespeopleApiService)(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(HostService));\n };\n SalespeopleApiService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: SalespeopleApiService,\n factory: SalespeopleApiService.ɵfac,\n providedIn: 'root'\n });\n return SalespeopleApiService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n// *********************************\nlet CancellationRequestService = /*#__PURE__*/(() => {\n class CancellationRequestService {\n constructor(svc) {\n this.svc = svc;\n }\n create(accountGroupId, partnerId, lineItemId, requestingUserId, reason, message, status) {\n const req = {\n accountGroupId: accountGroupId,\n partnerId: partnerId,\n lineItemId: lineItemId,\n requestingUserId: requestingUserId,\n status: status,\n reason: reason,\n message: message\n };\n return this.svc.create(req);\n }\n list(partnerId, accountGroupId, marketId) {\n const req = {\n partnerId: partnerId,\n accountGroupId: accountGroupId\n };\n if (!!marketId) {\n req.marketId = marketId;\n }\n return this.svc.list(req).pipe(map(resp => resp?.requests ?? []));\n }\n updateStatus(cancellationRequestId, cancellationRequestStatus, userId) {\n const req = {\n cancellationRequestId: cancellationRequestId,\n status: cancellationRequestStatus,\n userId: userId\n };\n return this.svc.updateStatus(req);\n }\n isConfigValid(partnerId, accountGroupId) {\n const req = {\n partnerId: partnerId,\n accountGroupId: accountGroupId\n };\n return this.svc.isConfigValid(req).pipe(map(resp => resp.isValid));\n }\n }\n CancellationRequestService.ɵfac = function CancellationRequestService_Factory(t) {\n return new (t || CancellationRequestService)(i0.ɵɵinject(CancellationRequestsApiService));\n };\n CancellationRequestService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: CancellationRequestService,\n factory: CancellationRequestService.ɵfac,\n providedIn: 'root'\n });\n return CancellationRequestService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\nvar Sort = /*#__PURE__*/function (Sort) {\n Sort[Sort[\"Updated\"] = 0] = \"Updated\"; // Only exists to communicate that this is currently the only sort option\n return Sort;\n}(Sort || {});\nvar SortDirection = /*#__PURE__*/function (SortDirection) {\n SortDirection[SortDirection[\"Descending\"] = 0] = \"Descending\"; // Only exists to communicate that this is currently the only sort option\n return SortDirection;\n}(SortDirection || {});\nlet BusinessService = /*#__PURE__*/(() => {\n class BusinessService {\n constructor(svc) {\n this.svc = svc;\n }\n search(partner, market, sort, direction, pageSize = 10) {\n const req = {\n partnerId: partner,\n marketId: market,\n fieldMask: {\n paths: ['external_id', 'updated']\n },\n pagingOptions: {\n pageSize: pageSize\n }\n };\n return this.svc.search(req).pipe(map(resp => this.returnBusinessResult(resp)), catchError(err => throwError(this.returnSearchError(err))));\n }\n searchBusinessesByContactEmail(partner, market, contactEmailQuery, assignedUserId) {\n const req = {\n partnerId: partner,\n marketId: market,\n contactEmailQuery: contactEmailQuery,\n fieldMask: {\n paths: ['external_id', 'updated']\n }\n };\n if (assignedUserId) {\n req.assignedUserId = assignedUserId;\n }\n return this.svc.searchBusinessesByContactEmail(req).pipe(map(resp => this.returnBusinessResult(resp)), catchError(err => throwError(this.returnSearchError(err))));\n }\n getPrimaryContact(accountId, partnerId, marketId) {\n const req = new GetAccountPrimaryContactRequest({\n accountId: accountId,\n partnerId: partnerId,\n marketId: marketId\n });\n return this.svc.getAccountPrimaryContact(req).pipe(map(resp => resp?.contactId));\n }\n setPrimaryContact(contactId, accountId, partnerId, marketId) {\n const req = new SetAccountPrimaryContactRequest({\n contactId: contactId,\n accountId: accountId,\n partnerId: partnerId,\n marketId: marketId\n });\n return this.svc.setAccountPrimaryContact(req).pipe(mapTo(null));\n }\n getLatestSalesActivityForAccounts(partnerId, marketId, accountIds) {\n const req = new GetSalesActivityForAccountsRequest({\n partnerId: partnerId,\n marketId: marketId,\n accountIds: accountIds\n });\n return this.svc.getSalesActivityForAccounts(req).pipe(map(resp => resp?.accountsLatestSalesActivity));\n }\n returnBusinessResult(resp) {\n return resp.businesses.map(b => ({\n accountGroupId: b.accountGroupId,\n updated: b.updated\n }));\n }\n returnSearchError(err) {\n if (err?.status === 404) {\n return of([]);\n }\n return err;\n }\n }\n BusinessService.ɵfac = function BusinessService_Factory(t) {\n return new (t || BusinessService)(i0.ɵɵinject(BusinessApiService));\n };\n BusinessService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: BusinessService,\n factory: BusinessService.ɵfac,\n providedIn: 'root'\n });\n return BusinessService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\nlet ActionListsService = /*#__PURE__*/(() => {\n class ActionListsService {\n constructor(svc) {\n this.svc = svc;\n }\n listActionLists(partnerId, marketId, searchString, pageIndex, pageSize) {\n const req = {\n partnerId: partnerId,\n marketId: marketId,\n searchString: searchString,\n pagingOptions: {\n pageIndex: pageIndex,\n pageSize: pageSize\n }\n };\n return this.svc.listActionLists(req).pipe(catchError(err => {\n if (err.status === 404) {\n return of(new ListActionListsResponse());\n }\n throw err;\n }));\n }\n addAccountsToActionList(partnerId, marketId, listName, accountGroupIds) {\n const req = {\n partnerId: partnerId,\n marketId: marketId,\n listName: listName,\n accountGroupIds: accountGroupIds\n };\n return this.svc.addAccountsToActionList(req);\n }\n }\n ActionListsService.ɵfac = function ActionListsService_Factory(t) {\n return new (t || ActionListsService)(i0.ɵɵinject(ActionListsApiService));\n };\n ActionListsService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ActionListsService,\n factory: ActionListsService.ɵfac,\n providedIn: 'root'\n });\n return ActionListsService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\nlet ContactsService = /*#__PURE__*/(() => {\n class ContactsService {\n constructor(svc) {\n this.svc = svc;\n }\n resendUserWelcomeEmail(partnerID, subjectID) {\n const resendRequest = {\n partnerId: partnerID,\n subjectId: subjectID\n };\n return this.svc.resendUserWelcomeEmail(resendRequest).pipe(map(response => ({\n success: response.notificationId !== ''\n })));\n }\n getContactsForAccounts(partnerID, marketID, accountIDs) {\n const getContactsRequest = {\n partnerId: partnerID,\n marketId: marketID,\n accountIds: accountIDs\n };\n return this.svc.getContactsForAccounts(getContactsRequest).pipe(map(response => ({\n contacts: response?.contacts || []\n })));\n }\n create(partnerId, marketId, accountGroupIds, contactAttributes) {\n const r = new CreateContactRequest({\n partnerId: partnerId,\n marketId: marketId,\n accountGroupIds: accountGroupIds,\n title: contactAttributes.title,\n firstName: contactAttributes.firstName,\n lastName: contactAttributes.lastName,\n phoneNumber: contactAttributes.phoneNumber,\n phoneNumberCountry: contactAttributes.phoneCountryCode,\n phoneNumberExtension: contactAttributes.phoneExtension,\n email: contactAttributes.email,\n notes: contactAttributes.notes\n });\n return this.svc.create(r).pipe(map(resp => resp.contact));\n }\n update(partnerId, marketId, contact, updatedFields) {\n const updateRequest = new UpdateContactRequest({\n partnerId: partnerId,\n marketId: marketId,\n contact: contact,\n mutatorMask: new FieldMask({\n paths: updatedFields\n })\n });\n return this.svc.update(updateRequest);\n }\n delete(partnerId, marketId, contactId) {\n if (!partnerId || !marketId || !contactId) {\n throw new Error('partnerId, marketId, and contactId required to delete a contact');\n }\n const deleteRequest = new DeleteContactRequest({\n partnerId: partnerId,\n marketId: marketId,\n contactId: contactId\n });\n return this.svc.delete(deleteRequest);\n }\n listContactsForBusiness(businessId, paths) {\n if (!businessId) {\n throw new Error('businessId required to retrieve contacts for a business');\n }\n const listRequest = new ListContactsForBusinessRequest({\n fieldMask: new FieldMask({\n paths: paths\n }),\n pagingOptions: new PagedRequestOptions({\n pageSize: 100\n }),\n accountGroupId: businessId\n });\n return this.svc.listContactsForBusiness(listRequest).pipe(map(res => res.contacts));\n }\n }\n ContactsService.ɵfac = function ContactsService_Factory(t) {\n return new (t || ContactsService)(i0.ɵɵinject(ContactsApiService));\n };\n ContactsService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ContactsService,\n factory: ContactsService.ɵfac,\n providedIn: 'root'\n });\n return ContactsService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\nlet SalespeopleService = /*#__PURE__*/(() => {\n class SalespeopleService {\n constructor(svc) {\n this.svc = svc;\n }\n isPermittedToCreateSalespersonForUser(userID) {\n return this.sendCreateSalespersonForUserRequest(userID, '', false, true).pipe(mapTo(true), catchError(_ => of(false)));\n }\n createSalespersonForUser(userID, marketID, isSalesManager = false) {\n return this.sendCreateSalespersonForUserRequest(userID, marketID, isSalesManager, false);\n }\n // returns salesperson efforts stats mapped to opportunityIds\n getMultiOpportunitySalespersonEfforts(opportunityIds) {\n const req = new GetMultiOpportunityEffortsRequest({\n opportunityIds: opportunityIds\n });\n return this.svc.getMultiOpportunityEfforts(req).pipe(map(resp => resp?.opportunityEfforts));\n }\n sendCreateSalespersonForUserRequest(userID, marketID, isSalesManager = false, authCheckOnly = false) {\n const req = {\n userId: userID,\n marketId: marketID,\n isSalesManager: isSalesManager,\n authCheckOnly: authCheckOnly\n };\n return this.svc.createSalespersonForUser(req);\n }\n sendPasswordResetEmail(partnerId, salesPersonId, usePlatformDefaultDomain) {\n const req = new SendPasswordResetEmailRequest({\n partnerId: partnerId,\n salesPersonId: salesPersonId,\n usePlatformDefaultDomain: usePlatformDefaultDomain\n });\n return this.svc.sendPasswordResetEmail(req);\n }\n }\n SalespeopleService.ɵfac = function SalespeopleService_Factory(t) {\n return new (t || SalespeopleService)(i0.ɵɵinject(SalespeopleApiService));\n };\n SalespeopleService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: SalespeopleService,\n factory: SalespeopleService.ɵfac,\n providedIn: 'root'\n });\n return SalespeopleService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\nlet CampaignSDKService = /*#__PURE__*/(() => {\n class CampaignSDKService {\n constructor(campaignApiService) {\n this.campaignApiService = campaignApiService;\n }\n getMultiCampaigns(partnerId, marketId, accountGroupId, campaignIds) {\n return this.campaignApiService.getMultiCampaigns({\n partnerId: partnerId,\n marketId: marketId,\n accountGroupId: accountGroupId,\n campaignIds: campaignIds\n }).pipe(map(resp => resp.campaigns));\n }\n lookupCampaigns(partnerId, marketId, searchTerm, options) {\n const request = {\n partnerId: partnerId,\n marketId: marketId\n };\n if (!!searchTerm) {\n request.searchTerm = searchTerm;\n }\n request.offset = options?.offset || request.offset;\n request.pageSize = options?.pageSize || request.pageSize;\n request.focus = options?.filters?.focus || request.focus;\n request.state = options?.filters?.state || request.state;\n request.status = options?.filters?.status || request.status;\n return this.campaignApiService.lookupCampaigns(request).pipe(map(resp => resp.campaigns));\n }\n addContactToCampaign(partnerId, marketId, campaignId, unifiedUserId, contact) {\n const request = {\n partnerId: partnerId,\n marketId: marketId,\n campaignId: campaignId,\n senderUnifiedUserId: unifiedUserId,\n contact: {\n emailAddress: contact.emailAddress,\n accountGroupId: contact.accountGroupId\n }\n };\n return this.campaignApiService.addContactToCampaign(request);\n }\n }\n CampaignSDKService.ɵfac = function CampaignSDKService_Factory(t) {\n return new (t || CampaignSDKService)(i0.ɵɵinject(CampaignApiService));\n };\n CampaignSDKService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: CampaignSDKService,\n factory: CampaignSDKService.ɵfac,\n providedIn: 'root'\n });\n return CampaignSDKService;\n})();\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && void 0;\n})();\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { AccountField, AccountLatestSalesActivity, ActionList, ActionListsService, AddAccountsToActionListResponse, BusinessService, CampaignSDKService, CancellationRequest, CancellationRequestReason, CancellationRequestService, CancellationRequestStatus, CancellationRequestsApiService, Contact, ContactsService, CreateSalespersonForUserResponse, EffortAggregate, IsConfigValidRequest, IsConfigValidResponse, SortDirection$1 as ListAccountSortDirection, ListActionListsResponse, PagedRequestOptions, SalespeopleService, Sort, SortD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AAWC,GAAKC,EAAG,EAAK,CAAC,CAAC,CACvH,CACA,yBAAyBJ,EAAQK,EAAUC,EAAiB,GAAO,CACjE,OAAO,KAAK,oCAAoCN,EAAQK,EAAUC,EAAgB,EAAK,CACzF,CAEA,sCAAsCC,EAAgB,CACpD,IAAMC,EAAM,IAAIC,EAAkC,CAChD,eAAgBF,CAClB,CAAC,EACD,OAAO,KAAK,IAAI,2BAA2BC,CAAG,EAAE,KAAKE,EAAIC,GAAQA,GAAM,kBAAkB,CAAC,CAC5F,CACA,oCAAoCX,EAAQK,EAAUC,EAAiB,GAAOM,EAAgB,GAAO,CACnG,IAAMJ,EAAM,CACV,OAAQR,EACR,SAAUK,EACV,eAAgBC,EAChB,cAAeM,CACjB,EACA,OAAO,KAAK,IAAI,yBAAyBJ,CAAG,CAC9C,CACA,uBAAuBK,EAAWC,EAAeC,EAA0B,CACzE,IAAMP,EAAM,IAAIQ,EAA8B,CAC5C,UAAWH,EACX,cAAeC,EACf,yBAA0BC,CAC5B,CAAC,EACD,OAAO,KAAK,IAAI,uBAAuBP,CAAG,CAC5C,CACF,CACA,OAAAV,EAAmB,UAAO,SAAoCmB,EAAG,CAC/D,OAAO,IAAKA,GAAKnB,GAAuBoB,EAASC,CAAqB,CAAC,CACzE,EACArB,EAAmB,WAA0BsB,EAAmB,CAC9D,MAAOtB,EACP,QAASA,EAAmB,UAC5B,WAAY,MACd,CAAC,EACMA,CACT,GAAG","names":["Salesperson","_Salesperson","proto","m","kwargs","toReturn","Contact","_Contact","proto","m","kwargs","toReturn","CreateSalespersonForUserRequest","_CreateSalespersonForUserRequest","proto","m","kwargs","toReturn","CreateSalespersonForUserResponse","_CreateSalespersonForUserResponse","EffortAggregate","_EffortAggregate","proto","m","obj","k","kwargs","toReturn","GetMultiOpportunityEffortsRequest","_GetMultiOpportunityEffortsRequest","proto","m","kwargs","toReturn","GetMultiOpportunityEffortsResponse","_GetMultiOpportunityEffortsResponse","obj","k","EffortAggregate","GetSalespersonByEmailRequest","_GetSalespersonByEmailRequest","proto","m","kwargs","toReturn","GetSalespersonByEmailResponse","_GetSalespersonByEmailResponse","Salesperson","SendPasswordResetEmailRequest","_SendPasswordResetEmailRequest","proto","m","kwargs","toReturn","environment","hostMap","HostService","t","ɵɵdefineInjectable","SalespeopleApiService","http","hostService","HttpHeaders","r","request","GetSalespersonByEmailRequest","map","resp","GetSalespersonByEmailResponse","CreateSalespersonForUserRequest","CreateSalespersonForUserResponse","GetMultiOpportunityEffortsRequest","GetMultiOpportunityEffortsResponse","SendPasswordResetEmailRequest","__spreadProps","__spreadValues","t","ɵɵinject","HttpClient","HostService","ɵɵdefineInjectable","SalespeopleService","svc","userID","mapTo","catchError","_","of","marketID","isSalesManager","opportunityIds","req","GetMultiOpportunityEffortsRequest","map","resp","authCheckOnly","partnerId","salesPersonId","usePlatformDefaultDomain","SendPasswordResetEmailRequest","t","ɵɵinject","SalespeopleApiService","ɵɵdefineInjectable"],"x_google_ignoreList":[0]}