Removed store constants.
This commit is contained in:
parent
65c9ce64c2
commit
3174609d6f
2 changed files with 0 additions and 445 deletions
|
|
@ -1,191 +0,0 @@
|
|||
/* eslint-disable camelcase */
|
||||
/* eslint-disable jsdoc/check-tag-names */
|
||||
/**
|
||||
* @constant API_VERSION
|
||||
* @endpoint
|
||||
* @private
|
||||
* @type {number}
|
||||
* @description The version number utilized to access the web api endpoints.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const API_VERSION = Object.freeze('1');
|
||||
|
||||
/**
|
||||
* @member APIs
|
||||
* @memberof StoreConstants
|
||||
* @endpoint constant
|
||||
* @description
|
||||
* This store enumeration is used to specify the category of api by providing a segment of the API URL.
|
||||
* @property {string} ANALYTICS - The Analytics API (see {@link https://digitalapi.dev.safelite.io/analytics/swagger/index.html}).
|
||||
* @property {string} AUTHENTICATION - The Authentication API (see {@link https://digitalapi.dev.safelite.io/clientauth/swagger/index.html}).
|
||||
* @property {string} CONTENT - The Content API (see {@link https://digitalapi.dev.safelite.io/content/swagger/index.html}).
|
||||
* @property {string} COVERAGE - The Coverage API (see {@link https://digitalapi.dev.safelite.io/coverage/swagger/index.html}).
|
||||
* @property {string} EXPERIMENTS - The Experiments API (see {@link https://digitalapi.dev.safelite.io/experiments/swagger/index.html}).
|
||||
* @property {string} GOOGLE - The Google Maps API (see {@link https://developers.google.com/maps/documentation}).
|
||||
* @property {string} LOCATION - The Location API (see {@link https://digitalapi.dev.safelite.io/location/swagger/index.html}).
|
||||
* @property {string} PARTS - The Parts API (see {@link https://digitalapi.dev.safelite.io/parts/swagger/index.html}).
|
||||
* @property {string} PRICE - The Price API (see {@link https://digitalapi.dev.safelite.io/price/swagger/index.html}).
|
||||
* @property {string} VEHICLE - The Vehicle API (see {@link https://digitalapi.dev.safelite.io/vehicle/swagger/index.html}).
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const APIs = Object.freeze({
|
||||
ANALYTICS: `analytics/api/v${API_VERSION}/analytics/`,
|
||||
AUTHENTICATION: `clientauth/api/v${API_VERSION}/clientauth/`,
|
||||
CONTENT: `content/api/v${API_VERSION}/content/`,
|
||||
COVERAGE: `coverage/api/v${API_VERSION}/coverage/`,
|
||||
EXPERIMENTS: `experiments/api/v${API_VERSION}/experiments/`,
|
||||
GOOGLE: 'https://maps.googleapis.com/maps/api/js?key={apiKey}&libraries=places',
|
||||
LOCATION: `location/api/v${API_VERSION}/location/`,
|
||||
PARTS: `parts/api/v${API_VERSION}/parts/`,
|
||||
PRICE: `price/api/v${API_VERSION}/price/`,
|
||||
VEHICLE: `vehicle/api/v${API_VERSION}/vehicle/`
|
||||
});
|
||||
|
||||
/**
|
||||
* @member ENDPOINTs
|
||||
* @memberof StoreConstants
|
||||
* @endpoint
|
||||
* @description
|
||||
* This store enumeration is used to specify the individual endpoints by providing the primary segment of the EndPoint URL.
|
||||
* @property {object} ANALYTICS - The Analytics API Category.
|
||||
* @property {string} ANALYTICS.CustomEvent - The ANALYTICS.CustomEvent EndPoint URL Segment.
|
||||
* @property {string} ANALYTICS.ExperimentsByUser - The ANALYTICS.ExperimentsByUser EndPoint URL Segment.
|
||||
* @property {string} ANALYTICS.PageView - The ANALYTICS.PageView EndPoint URL Segment.
|
||||
* @property {string} ANALYTICS.Session - The ANALYTICS.Session EndPoint URL Segment.
|
||||
* @property {object} AUTHENTICATION - The Authentication API Category.
|
||||
* @property {string} AUTHENTICATION.ClientTag - The AUTHENTICATION.ClientTag EndPoint URL Segment.
|
||||
* @property {object} CONTENT - The Content API Category.
|
||||
* @property {string} CONTENT.PageData - The CONTENT.PageData EndPoint URL Segment.
|
||||
* @property {object} COVERAGE - The Coverage API Category.
|
||||
* @property {string} COVERAGE.PolicyInfo - The COVERAGE.PolicyInfo EndPoint URL Segment.
|
||||
* @property {object} EXPERIMENTS - The Experiments API Category.
|
||||
* @property {string} EXPERIMENTS.ExperimentExposure - The EXPERIMENTS.ExperimentExposureExperiments EndPoint URL Segment.
|
||||
* @property {string} EXPERIMENTS.ExperimentsForTrigger - The EXPERIMENTS.ExperimentsForTrigger EndPoint URL Segment.
|
||||
* @property {object} GOOGLE - The Google Maps API Category.
|
||||
* @property {string} GOOGLE.Places - The GOOGLE.Places (Google Maps) EndPoint URL Segment.
|
||||
* @property {object} LOCATION - The Location API Category.
|
||||
* @property {string} LOCATION.ServiceabilityDetails - The LOCATION.ServiceabilityDetails EndPoint URL Segment.
|
||||
* @property {string} LOCATION.Zip - The LOCATION.Zip EndPoint URL Segment.
|
||||
* @property {object} PARTS - The Parts API Category.
|
||||
* @property {string} PARTS.CapabilityAnswers - The PARTS.CapabilityAnswers EndPoint URL Segment.
|
||||
* @property {string} PARTS.CapabilityQuestions - The PARTS.CapabilityQuestions EndPoint URL Segment.
|
||||
* @property {string} PARTS.DamageOptions - The PARTS.DamageOptions EndPoint URL Segment.
|
||||
* @property {string} PARTS.Parts - The PARTS.Parts EndPoint URL Segment.
|
||||
* @property {string} PARTS.PartsOrQuestions - The PARTS.PartsOrQuestions EndPoint URL Segment.
|
||||
* @property {string} PARTS.RainDefense - The PARTS.RainDefense EndPoint URL Segment.
|
||||
* @property {string} PARTS.SupportingItems - The PARTS.SupportingItems EndPoint URL Segment.
|
||||
* @property {string} PARTS.Wipers - The PARTS.Wipers EndPoint URL Segment.
|
||||
* @property {object} PRICE - The Price API Category.
|
||||
* @property {string} PRICE.OrderItems - The PRICE.OrderItems EndPoint URL Segment.
|
||||
* @property {object} VEHICLE - The Vehicle API Category.
|
||||
* @property {string} VEHICLE.Makes - The VEHICLE.Makes EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.Models - The VEHICLE.Models EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.Styles - The VEHICLE.Styles EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.Vehicle - The VEHICLE.Vehicle EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.Years - The VEHICLE.Years EndPoint URL Segment.
|
||||
* @property {object} VEHICLE.VIN - The Vehicle VIN API Category.
|
||||
* @property {string} VEHICLE.VIN.ByAddress - The VEHICLE.VIN.ByAddress EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.VIN.ByPlate - The VEHICLE.VIN.ByPlate EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.VIN.ByVIN - The VEHICLE.VIN.ByVIN EndPoint URL Segment.
|
||||
* @property {string} VEHICLE.VIN.IsByAddress - The VEHICLE.VIN.IsByAddress EndPoint URL Segment.
|
||||
* @static
|
||||
* @readonly
|
||||
* @default
|
||||
*/
|
||||
const ENDPOINTs = Object.freeze({
|
||||
ANALYTICS: {
|
||||
CustomEvent: `${APIs.ANALYTICS}log-custom-event`,
|
||||
ExperimentsByUser: `${APIs.ANALYTICS}get-experiments/{}`,
|
||||
PageView: `${APIs.ANALYTICS}log-page-view`,
|
||||
Session: `${APIs.ANALYTICS}initialize`
|
||||
},
|
||||
AUTHENTICATION: {
|
||||
ClientTag: `${APIs.AUTHENTICATION}validate-client-tag/{}`
|
||||
},
|
||||
CONTENT: {
|
||||
PageData: `${APIs.CONTENT}{}/{}`
|
||||
},
|
||||
COVERAGE: {
|
||||
PolicyInfo: `${APIs.COVERAGE}get-policy-information`
|
||||
},
|
||||
EXPERIMENTS: {
|
||||
ExperimentExposure: `${APIs.EXPERIMENTS}log-exposure`,
|
||||
ExperimentsForTrigger: `${APIs.EXPERIMENTS}run`
|
||||
},
|
||||
GOOGLE: {
|
||||
Places: APIs.GOOGLE
|
||||
},
|
||||
LOCATION: {
|
||||
ServiceabilityDetails: `${APIs.LOCATION}serviceability-details?zip={}&carId={}&{}&{}`,
|
||||
Zip: `${APIs.LOCATION}zip/{}`
|
||||
},
|
||||
PARTS: {
|
||||
CapabilityAnswers: `${APIs.PARTS}part-from-capability-answer`,
|
||||
CapabilityQuestions: `${APIs.PARTS}capability-questions/{}/{}`,
|
||||
DamageOptions: `${APIs.PARTS}damage-options/{}`,
|
||||
Parts: `${APIs.PARTS}parts`,
|
||||
PartsOrQuestions: `${APIs.PARTS}parts-or-questions`,
|
||||
RainDefense: `${APIs.PARTS}rain-defense`,
|
||||
SupportingItems: `${APIs.PARTS}supporting-items`,
|
||||
Wipers: `${APIs.PARTS}wipers/{}/{}`
|
||||
},
|
||||
PRICE: {
|
||||
OrderItems: `${APIs.PRICE}order-items?{}`
|
||||
},
|
||||
VEHICLE: {
|
||||
Makes: `${APIs.VEHICLE}makes/{}`,
|
||||
Models: `${APIs.VEHICLE}models/{}/{}`,
|
||||
Styles: `${APIs.VEHICLE}styles/{}/{}/{}`,
|
||||
Vehicle: `${APIs.VEHICLE}lookup/{}/{}/{}/{}`,
|
||||
Years: `${APIs.VEHICLE}years`,
|
||||
VIN: {
|
||||
ByAddress: `${APIs.VEHICLE}lookup-vin-by-address`,
|
||||
ByPlate: `${APIs.VEHICLE}lookup-vin-by-plate`,
|
||||
ByVIN: `${APIs.VEHICLE}lookup`,
|
||||
IsByAddress: `${APIs.VEHICLE}is-vin-by-address-permissible?state={}`
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* @member HTTP_VERBS
|
||||
* @memberof StoreConstants
|
||||
* @endpoint
|
||||
* @description
|
||||
* This store enumeration is used by endpoints to specify the type of http request.
|
||||
* @property {string} GET - The http verb **get**
|
||||
* @property {string} POST - The http verb **post**
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const HTTP_VERBS = Object.freeze({ GET: 'get', POST: 'post' });
|
||||
|
||||
/**
|
||||
* @module StoreConstants
|
||||
* @endpoint constant
|
||||
* @type {StoreConstants}
|
||||
* @description
|
||||
* Constants that are utilized by the Store and Endpoint system.
|
||||
* @author T-Wrecks Team
|
||||
* @copyright Safelite
|
||||
* @property {StoreConstants.APIs} APIs
|
||||
* This store enumeration is used to specify the category of api by providing a segment of the API URL.
|
||||
* @remarks
|
||||
* This is being exposed for testing purposes.
|
||||
* @property {StoreConstants.ENDPOINTs} ENDPOINTs
|
||||
* This store enumeration is used to specify the specific endpoint URLs.
|
||||
* @property {StoreConstants.HTTP_VERBS} HTTP_VERBS
|
||||
* This store enumeration is used by endpoints to specify the type of http request.
|
||||
* @static
|
||||
* @readonly
|
||||
* @default
|
||||
*/
|
||||
const StoreConstants = {
|
||||
APIs,
|
||||
ENDPOINTs,
|
||||
HTTP_VERBS
|
||||
};
|
||||
|
||||
export default StoreConstants;
|
||||
|
|
@ -1,254 +0,0 @@
|
|||
/* eslint-disable max-len */
|
||||
/* eslint-disable camelcase */
|
||||
import PAYLOAD_PROPERTIES from '@/store/endpoints/property-resolver.js';
|
||||
|
||||
/**
|
||||
* @member ANALYTICS
|
||||
* @memberof DefaultPayloads
|
||||
* @endpoint
|
||||
* @description
|
||||
* This default payload object is used to specify the default payloads for the Analytics Service.
|
||||
* @see {@link https://digitalapi.dev.safelite.io/analytics/swagger/index.html}
|
||||
* @property {object} LogCustomEventPayload
|
||||
* This default payload object provides payload properties for a call to the **log-custom-event** endpoint.
|
||||
* @property {object} LogPageViewPayload
|
||||
* This default payload object provides payload properties for a call to the **log-page-view** endpoint.
|
||||
* @property {object} InitializeSessionPayload
|
||||
* This default payload object provides payload properties for a call to the **initialize** endpoint.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const ANALYTICS = {
|
||||
LogCustomEventPayload: {},
|
||||
LogPageViewPayload: {},
|
||||
InitializeSessionPayload: {}
|
||||
};
|
||||
// #region ANALYTICS Custom Event Default Payload Setup
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.UserId.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.SessionKey.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.SessionId.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.PageName.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.ApplicationName.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.Category.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.Action.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.Label.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.Value.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.ShouldUseSessionId.Name] = '';
|
||||
ANALYTICS.LogCustomEventPayload[PAYLOAD_PROPERTIES.ExperimentsForUser.Name] = '';
|
||||
// #endregion
|
||||
// #region ANALYTICS Page View Default Payload Setup
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.UserId.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.SessionKey.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.SessionId.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.PageName.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.ApplicationName.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.Action.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.Event.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.ShouldUseSessionId.Name] = '';
|
||||
ANALYTICS.LogPageViewPayload[PAYLOAD_PROPERTIES.ExperimentsForUser.Name] = '';
|
||||
// #endregion
|
||||
// #region ANALYTICS Session Default Payload Setup
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.ApplicationName.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.UserId.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.DeviceId.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.SessionId.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.UserAgent.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.OperatorId.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.UserName.Name] = '';
|
||||
ANALYTICS.InitializeSessionPayload[PAYLOAD_PROPERTIES.Referrer.Name] = '';
|
||||
// #endregion
|
||||
// #region ANALYTICS Deep Freeze
|
||||
Object.freeze(ANALYTICS.LogCustomEventPayload);
|
||||
Object.freeze(ANALYTICS.LogPageViewPayload);
|
||||
Object.freeze(ANALYTICS.InitializeSessionPayload);
|
||||
Object.freeze(ANALYTICS);
|
||||
// #endregion
|
||||
|
||||
/**
|
||||
* @member COVERAGE
|
||||
* @memberof DefaultPayloads
|
||||
* @endpoint
|
||||
* @description
|
||||
* This default payload object is used to specify the default payloads for the Coverage Service.
|
||||
* @see {@link https://digitalapi.dev.safelite.io/coverage/swagger/index.html}
|
||||
* @property {object} PolicyInfoPayload
|
||||
* This default payload object provides payload properties for a call to the **get-policy-information** endpoint.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const COVERAGE = {
|
||||
PolicyInfoPayload: {}
|
||||
};
|
||||
// #region COVERAGE Policy Info Default Payload Setup
|
||||
COVERAGE.PolicyInfoPayload[PAYLOAD_PROPERTIES.AccountNumber.Name] = '';
|
||||
COVERAGE.PolicyInfoPayload[PAYLOAD_PROPERTIES.PolicyNumber.Name] = '';
|
||||
COVERAGE.PolicyInfoPayload[PAYLOAD_PROPERTIES.DateOfLoss.Name] = '';
|
||||
COVERAGE.PolicyInfoPayload[PAYLOAD_PROPERTIES.ZipCodeForCoverage.Name] = '';
|
||||
COVERAGE.PolicyInfoPayload[PAYLOAD_PROPERTIES.PlaceholderCorrelationId.Name] = '';
|
||||
// #endregion
|
||||
// #region COVERAGE Deep Freeze
|
||||
Object.freeze(COVERAGE.PolicyInfoPayload);
|
||||
Object.freeze(COVERAGE);
|
||||
// #endregion
|
||||
|
||||
/**
|
||||
* @member EXPERIMENTS
|
||||
* @memberof DefaultPayloads
|
||||
* @endpoint
|
||||
* @description
|
||||
* This default payload object is used to specify the default payloads for the Experiment Service.
|
||||
* @see {@link https://digitalapi.dev.safelite.io/experiments/swagger/index.html}
|
||||
* @property {object} LogExperimentExposurePayload
|
||||
* This default payload object provides payload properties for a call to the **log-exposure** endpoint.
|
||||
* @property {object} RunExperimentsForTriggerPayload
|
||||
* This default payload object provides payload properties for a call to the **run** endpoint.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const EXPERIMENTS = {
|
||||
LogExperimentExposurePayload: {},
|
||||
RunExperimentsForTriggerPayload: {}
|
||||
};
|
||||
// #region EXPERIMENTS Experiment Exposure Default Payload Setup
|
||||
EXPERIMENTS.LogExperimentExposurePayload[PAYLOAD_PROPERTIES.ExperimentForLogging.Name] = '';
|
||||
// #endregion
|
||||
// #region EXPERIMENTS Experiments For Trigger Default Payload Setup
|
||||
EXPERIMENTS.RunExperimentsForTriggerPayload[PAYLOAD_PROPERTIES.ApplicationName.Name] = '';
|
||||
EXPERIMENTS.RunExperimentsForTriggerPayload[PAYLOAD_PROPERTIES.UserId.Name] = '';
|
||||
EXPERIMENTS.RunExperimentsForTriggerPayload[PAYLOAD_PROPERTIES.TriggerEvent.Name] = '';
|
||||
EXPERIMENTS.RunExperimentsForTriggerPayload[PAYLOAD_PROPERTIES.TriggerValue.Name] = '';
|
||||
EXPERIMENTS.RunExperimentsForTriggerPayload[PAYLOAD_PROPERTIES.ExperimentOrder.Name] = '';
|
||||
// #endregion
|
||||
// #region EXPERIMENTS Deep Freeze
|
||||
Object.freeze(EXPERIMENTS.LogExperimentExposurePayload);
|
||||
Object.freeze(EXPERIMENTS.RunExperimentsForTriggerPayload);
|
||||
Object.freeze(EXPERIMENTS);
|
||||
// #endregion
|
||||
|
||||
/**
|
||||
* @member PARTS
|
||||
* @memberof DefaultPayloads
|
||||
* @endpoint
|
||||
* @description
|
||||
* This default payload object is used to specify the default payloads for the Part Service.
|
||||
* @see {@link https://digitalapi.dev.safelite.io/parts/swagger/index.html}
|
||||
* @property {object} ItemFromCapabilityAnswerPayload
|
||||
* This default payload object provides payload properties for a call to the **part-from-capability-answer** endpoint.
|
||||
* @property {object} PartsPayload
|
||||
* This default payload object provides payload properties for a call to the **parts** endpoint.
|
||||
* @property {object} PartsOrQuestionsPayload
|
||||
* This default payload object provides payload properties for a call to the **parts-or-question** endpoint.
|
||||
* @property {object} SupportingItemsPayload
|
||||
* This default payload object provides payload properties for a call to the **supporting-items** endpoint.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const PARTS = {
|
||||
ItemFromCapabilityAnswerPayload: {},
|
||||
PARTS_PartsPayload: {},
|
||||
PartsOrQuestionsPayload: {},
|
||||
SupportingItemsPayload: {}
|
||||
};
|
||||
// #region PARTS Item From Capability Answer Default Payload Setup
|
||||
PARTS.ItemFromCapabilityAnswerPayload[PAYLOAD_PROPERTIES.Part.Name] = '';
|
||||
PARTS.ItemFromCapabilityAnswerPayload[PAYLOAD_PROPERTIES.CapAnswerResults.Name] = '';
|
||||
// #endregion
|
||||
// #region PARTs Parts Default Payload Setup
|
||||
PARTS.PartsPayload[PAYLOAD_PROPERTIES.CarId.Name] = '';
|
||||
PARTS.PartsPayload[PAYLOAD_PROPERTIES.GlassPieces.Name] = '';
|
||||
PARTS.PartsPayload[PAYLOAD_PROPERTIES.AnswerResults.Name] = '';
|
||||
PARTS.PartsPayload[PAYLOAD_PROPERTIES.Zip.Name] = '';
|
||||
PARTS.PartsPayload[PAYLOAD_PROPERTIES.VIN.Name] = '';
|
||||
// #endregion
|
||||
// #region PARTs Parts Or Questions Default Payload Setup
|
||||
PARTS.PartsOrQuestionsPayload[PAYLOAD_PROPERTIES.CarId.Name] = '';
|
||||
PARTS.PartsOrQuestionsPayload[PAYLOAD_PROPERTIES.GlassPieces.Name] = '';
|
||||
PARTS.PartsOrQuestionsPayload[PAYLOAD_PROPERTIES.Zip.Name] = '';
|
||||
PARTS.PartsOrQuestionsPayload[PAYLOAD_PROPERTIES.VIN.Name] = '';
|
||||
// #endregion
|
||||
// #region PARTs Supporting Items Default Payload Setup
|
||||
PARTS.SupportingItemsPayload[PAYLOAD_PROPERTIES.CarId.Name] = '';
|
||||
PARTS.SupportingItemsPayload[PAYLOAD_PROPERTIES.DamageType.Name] = '';
|
||||
PARTS.SupportingItemsPayload[PAYLOAD_PROPERTIES.ParentAcctNumber.Name] = '';
|
||||
PARTS.SupportingItemsPayload[PAYLOAD_PROPERTIES.Parts.Name] = '';
|
||||
PARTS.SupportingItemsPayload[PAYLOAD_PROPERTIES.NumberOfChips.Name] = '';
|
||||
// #endregion
|
||||
// #region PARTS Deep Freeze
|
||||
Object.freeze(PARTS.ItemFromCapabilityAnswerPayload);
|
||||
Object.freeze(PARTS.PartsPayload);
|
||||
Object.freeze(PARTS.PartsOrQuestionsPayload);
|
||||
Object.freeze(PARTS.SupportingItemsPayload);
|
||||
Object.freeze(PARTS);
|
||||
// #endregion
|
||||
|
||||
/**
|
||||
* @member VEHICLE
|
||||
* @memberof DefaultPayloads
|
||||
* @endpoint
|
||||
* @description
|
||||
* This default payload object is used to specify the default payloads for the Vehicle Service.
|
||||
* @see {@link https://digitalapi.dev.safelite.io/vehicle/swagger/index.html}
|
||||
* @property {object} VIN - A subcategory of the Vehicle API that provides VIN related information.
|
||||
* @property {object} VIN.ByAddressLookupPayload
|
||||
* This default payload object provides payload properties for a call to the **lookup-vin-by-address** endpoint.
|
||||
* @property {object} VIN.ByPlateLookupPayload
|
||||
* This default payload object provides payload properties for a call to the **lookup-vin-by-plate** endpoint.
|
||||
* @property {object} VIN.ByLookupPayload
|
||||
* This default payload object provides payload properties for a call to the **lookup** endpoint.
|
||||
* @static
|
||||
* @readonly
|
||||
*/
|
||||
const VEHICLE = {
|
||||
VIN: {
|
||||
ByAddressLookupPayload: {},
|
||||
ByPlateLookupPayload: {},
|
||||
ByLookupPayload: {}
|
||||
}
|
||||
};
|
||||
// #region VEHICLE VIN By Address Lookup Default Payload Setup
|
||||
VIN.ByAddressLookupPayload[PAYLOAD_PROPERTIES.LicenseLastName.Name] = '';
|
||||
VIN.ByAddressLookupPayload[PAYLOAD_PROPERTIES.LicenseStreetAddr.Name] = '';
|
||||
VIN.ByAddressLookupPayload[PAYLOAD_PROPERTIES.LicenseZip.Name] = '';
|
||||
VIN.ByAddressLookupPayload[PAYLOAD_PROPERTIES.LicenseState.Name] = '';
|
||||
// #endregion
|
||||
// #region VEHICLE VIN By Plate Lookup Default Payload Setup
|
||||
VIN.ByPlateLookupPayload[PAYLOAD_PROPERTIES.LicensePlate.Name] = '';
|
||||
VIN.ByPlateLookupPayload[PAYLOAD_PROPERTIES.LicenseState.Name] = '';
|
||||
// #endregion
|
||||
// #region VEHICLE VIN By Lookup Default Payload Setup
|
||||
VIN.ByLookupPayload[PAYLOAD_PROPERTIES.VIN.Name] = '';
|
||||
// #endregion
|
||||
// #region VEHICLE Deep Freeze
|
||||
Object.freeze(VEHICLE.VIN.ByAddressLookupPayload);
|
||||
Object.freeze(VEHICLE.VIN.ByPlateLookupPayload);
|
||||
Object.freeze(VEHICLE.VIN.ByLookupPayload);
|
||||
Object.freeze(VEHICLE.VIN);
|
||||
Object.freeze(VEHICLE);
|
||||
// #endregion
|
||||
|
||||
/**
|
||||
* @module DefaultPayloads
|
||||
* @endpoint constant
|
||||
* @type {DefaultPayloads}
|
||||
* @author T-Wrecks Team
|
||||
* @copyright Safelite
|
||||
* @description Constants that are utilized by Endpoint system to provide default payloads.
|
||||
* @remarks This defines properties for payloads.
|
||||
* @property {DefaultPayloads.ANALYTICS} ANALYTICS - The Analytics API Category.
|
||||
* @property {DefaultPayloads.COVERAGE} COVERAGE - The Coverage API Category.
|
||||
* @property {DefaultPayloads.EXPERIMENTS} EXPERIMENTS - The Experiments API Category.
|
||||
* @property {DefaultPayloads.PARTS} PARTS - The Parts API Category.
|
||||
* @property {DefaultPayloads.VEHICLE} VEHICLE - The Vehicle API Category.
|
||||
* @static
|
||||
* @readonly
|
||||
* @default
|
||||
*/
|
||||
const DefaultPayloads = {
|
||||
ANALYTICS,
|
||||
COVERAGE,
|
||||
EXPERIMENTS,
|
||||
PARTS,
|
||||
VEHICLE
|
||||
};
|
||||
|
||||
export default Object.freeze(DefaultPayloads);
|
||||
Loading…
Reference in a new issue