Skip to content

Commit

Permalink
c1
Browse files Browse the repository at this point in the history
  • Loading branch information
sbansla committed Sep 12, 2024
1 parent 7abbc1b commit e3abac4
Show file tree
Hide file tree
Showing 539 changed files with 65,128 additions and 104,429 deletions.
7 changes: 3 additions & 4 deletions src/rest/accounts/V1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ export default class V1 extends Version {

/** Getter for authTokenPromotion resource */
get authTokenPromotion(): AuthTokenPromotionListInstance {
this._authTokenPromotion =
this._authTokenPromotion || AuthTokenPromotionListInstance(this);
this._authTokenPromotion = this._authTokenPromotion || AuthTokenPromotionListInstance(this);
return this._authTokenPromotion;
}

Expand All @@ -59,8 +58,8 @@ export default class V1 extends Version {

/** Getter for secondaryAuthToken resource */
get secondaryAuthToken(): SecondaryAuthTokenListInstance {
this._secondaryAuthToken =
this._secondaryAuthToken || SecondaryAuthTokenListInstance(this);
this._secondaryAuthToken = this._secondaryAuthToken || SecondaryAuthTokenListInstance(this);
return this._secondaryAuthToken;
}

}
91 changes: 45 additions & 46 deletions src/rest/accounts/v1/authTokenPromotion.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,26 @@
* Do not edit the class manually.
*/


import { inspect, InspectOptions } from "util";
import V1 from "../V1";
const deserialize = require("../../../base/deserialize");
const serialize = require("../../../base/serialize");
import { isValidPathParam } from "../../../base/utility";




export interface AuthTokenPromotionContext {

/**
* Update a AuthTokenPromotionInstance
*
* @param callback - Callback to handle processed record
*
* @returns Resolves to processed AuthTokenPromotionInstance
*/
update(
callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any
): Promise<AuthTokenPromotionInstance>;
update(callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any): Promise<AuthTokenPromotionInstance>

/**
* Provide a user-friendly representation
Expand All @@ -37,38 +40,32 @@ export interface AuthTokenPromotionContext {
[inspect.custom](_depth: any, options: InspectOptions): any;
}

export interface AuthTokenPromotionContextSolution {}
export interface AuthTokenPromotionContextSolution {
}

export class AuthTokenPromotionContextImpl
implements AuthTokenPromotionContext
{
export class AuthTokenPromotionContextImpl implements AuthTokenPromotionContext {
protected _solution: AuthTokenPromotionContextSolution;
protected _uri: string;


constructor(protected _version: V1) {
this._solution = {};
this._solution = { };
this._uri = `/AuthTokens/Promote`;
}

update(
callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any
): Promise<AuthTokenPromotionInstance> {
update(callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any): Promise<AuthTokenPromotionInstance> {

const instance = this;
let operationVersion = instance._version,
operationPromise = operationVersion.update({
uri: instance._uri,
method: "post",
});

operationPromise = operationPromise.then(
(payload) => new AuthTokenPromotionInstance(operationVersion, payload)
);

operationPromise = instance._version.setPromiseCallback(
operationPromise,
callback
);
operationPromise = operationVersion.update({ uri: instance._uri, method: "post" });

operationPromise = operationPromise.then(payload => new AuthTokenPromotionInstance(operationVersion, payload));


operationPromise = instance._version.setPromiseCallback(operationPromise,callback);
return operationPromise;


}

/**
Expand All @@ -85,6 +82,7 @@ export class AuthTokenPromotionContextImpl
}
}


interface AuthTokenPromotionPayload extends AuthTokenPromotionResource {}

interface AuthTokenPromotionResource {
Expand All @@ -100,13 +98,13 @@ export class AuthTokenPromotionInstance {
protected _context?: AuthTokenPromotionContext;

constructor(protected _version: V1, payload: AuthTokenPromotionResource) {
this.accountSid = payload.account_sid;
this.authToken = payload.auth_token;
this.accountSid = (payload.account_sid);
this.authToken = (payload.auth_token);
this.dateCreated = deserialize.iso8601DateTime(payload.date_created);
this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated);
this.url = payload.url;
this.url = (payload.url);

this._solution = {};
this._solution = { };
}

/**
Expand All @@ -131,8 +129,7 @@ export class AuthTokenPromotionInstance {
url: string;

private get _proxy(): AuthTokenPromotionContext {
this._context =
this._context || new AuthTokenPromotionContextImpl(this._version);
this._context = this._context || new AuthTokenPromotionContextImpl(this._version);
return this._context;
}

Expand All @@ -143,9 +140,9 @@ export class AuthTokenPromotionInstance {
*
* @returns Resolves to processed AuthTokenPromotionInstance
*/
update(
callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any
): Promise<AuthTokenPromotionInstance> {
update(callback?: (error: Error | null, item?: AuthTokenPromotionInstance) => any): Promise<AuthTokenPromotionInstance>

{
return this._proxy.update(callback);
}

Expand All @@ -161,15 +158,17 @@ export class AuthTokenPromotionInstance {
dateCreated: this.dateCreated,
dateUpdated: this.dateUpdated,
url: this.url,
};
}
}

[inspect.custom](_depth: any, options: InspectOptions) {
return inspect(this.toJSON(), options);
}
}

export interface AuthTokenPromotionSolution {}

export interface AuthTokenPromotionSolution {
}

export interface AuthTokenPromotionListInstance {
_version: V1;
Expand All @@ -179,36 +178,36 @@ export interface AuthTokenPromotionListInstance {
(): AuthTokenPromotionContext;
get(): AuthTokenPromotionContext;




/**
* Provide a user-friendly representation
*/
toJSON(): any;
[inspect.custom](_depth: any, options: InspectOptions): any;
}

export function AuthTokenPromotionListInstance(
version: V1
): AuthTokenPromotionListInstance {
export function AuthTokenPromotionListInstance(version: V1): AuthTokenPromotionListInstance {
const instance = (() => instance.get()) as AuthTokenPromotionListInstance;

instance.get = function get(): AuthTokenPromotionContext {
return new AuthTokenPromotionContextImpl(version);
};
}

instance._version = version;
instance._solution = {};
instance._solution = { };
instance._uri = ``;

instance.toJSON = function toJSON() {
return instance._solution;
};
}

instance[inspect.custom] = function inspectImpl(
_depth: any,
options: InspectOptions
) {
instance[inspect.custom] = function inspectImpl(_depth: any, options: InspectOptions) {
return inspect(instance.toJSON(), options);
};
}

return instance;
}


25 changes: 15 additions & 10 deletions src/rest/accounts/v1/credential.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
* Do not edit the class manually.
*/


import { inspect, InspectOptions } from "util";
import V1 from "../V1";
const deserialize = require("../../../base/deserialize");
Expand All @@ -20,13 +21,18 @@ import { isValidPathParam } from "../../../base/utility";
import { AwsListInstance } from "./credential/aws";
import { PublicKeyListInstance } from "./credential/publicKey";

export interface CredentialSolution {}



export interface CredentialSolution {
}

export interface CredentialListInstance {
_version: V1;
_solution: CredentialSolution;
_uri: string;


_aws?: AwsListInstance;
aws: AwsListInstance;
_publicKey?: PublicKeyListInstance;
Expand All @@ -43,7 +49,7 @@ export function CredentialListInstance(version: V1): CredentialListInstance {
const instance = {} as CredentialListInstance;

instance._version = version;
instance._solution = {};
instance._solution = { };
instance._uri = `/Credentials`;

Object.defineProperty(instance, "aws", {
Expand All @@ -52,7 +58,7 @@ export function CredentialListInstance(version: V1): CredentialListInstance {
instance._aws = AwsListInstance(instance._version);
}
return instance._aws;
},
}
});

Object.defineProperty(instance, "publicKey", {
Expand All @@ -61,19 +67,18 @@ export function CredentialListInstance(version: V1): CredentialListInstance {
instance._publicKey = PublicKeyListInstance(instance._version);
}
return instance._publicKey;
},
}
});

instance.toJSON = function toJSON() {
return instance._solution;
};
}

instance[inspect.custom] = function inspectImpl(
_depth: any,
options: InspectOptions
) {
instance[inspect.custom] = function inspectImpl(_depth: any, options: InspectOptions) {
return inspect(instance.toJSON(), options);
};
}

return instance;
}


Loading

0 comments on commit e3abac4

Please sign in to comment.