@localazy/ts-api
Advanced tools
Comparing version 1.0.11-alpha.0 to 1.0.11
@@ -29,2 +29,6 @@ import Constructor from './models/arguments/constructor'; | ||
import GetFileContents from './models/arguments/get-file-contents'; | ||
import DeleteKey from './models/arguments/delete-key'; | ||
import DeleteKeyResult from './models/responses/delete-key-result'; | ||
import UpdateKey from './models/arguments/update-key'; | ||
import UpdateKeyResult from './models/responses/update-key-result'; | ||
declare class LocalazyService { | ||
@@ -36,3 +40,3 @@ private projectToken; | ||
* List projects related to the project token. | ||
* @see https://localazy.com/docs/api/list-projects | ||
* @see https://localazy.com/docs/api/projects#list-projects | ||
*/ | ||
@@ -42,3 +46,3 @@ listProjects(options?: ListProjects, config?: CommonConfig): Promise<Project[]>; | ||
* Import content into Localazy. | ||
* @see https://localazy.com/docs/api/import | ||
* @see https://localazy.com/docs/api/import#import-content-to-a-project | ||
*/ | ||
@@ -48,3 +52,3 @@ import(options: Import, config?: CommonConfig): Promise<ImportResult>; | ||
* Retrieve list of available file formats and related options. | ||
* @see https://localazy.com/docs/api/import#retrieve-a-list-of-available-file-types | ||
* @see https://localazy.com/docs/api/import#list-available-file-types | ||
*/ | ||
@@ -54,3 +58,3 @@ listFormats(config?: CommonConfig): Promise<Format[]>; | ||
* List Localazy files. | ||
* @see https://localazy.com/docs/api/files | ||
* @see https://localazy.com/docs/api/files#list-files-in-project | ||
*/ | ||
@@ -60,3 +64,3 @@ listFiles(options: ListFiles, config?: CommonConfig): Promise<FileResult[]>; | ||
* Returns the given file contents. | ||
* @see https://localazy.com/docs/api/files | ||
* @see https://localazy.com/docs/api/files#list-file-content | ||
*/ | ||
@@ -71,3 +75,3 @@ getFileContents(options: GetFileContents, config?: CommonConfig): Promise<Blob>; | ||
* Retrieve list of webhooks for project. | ||
* @see https://localazy.com/docs/api/webhooks | ||
* @see https://localazy.com/docs/api/webhooks-api#list-webhooks-configuration | ||
*/ | ||
@@ -77,3 +81,3 @@ listWebhooks(options: ListWebhooks, config?: CommonConfig): Promise<ListWebhooksResult>; | ||
* Store a new webhooks configuration for the project. | ||
* @see https://localazy.com/docs/api/webhooks | ||
* @see https://localazy.com/docs/api/screenshot-management#create-a-new-screenshot | ||
*/ | ||
@@ -83,3 +87,3 @@ postWebhooks(options: PostWebhooks, config?: CommonConfig): Promise<PostWebhooksResult>; | ||
* Retrieve list of screenshots for project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#list-screenshots | ||
*/ | ||
@@ -89,3 +93,3 @@ listScreenshots(options: ListScreenshots, config?: CommonConfig): Promise<ListScreenshotsResult>; | ||
* Retrive list of screenshots tags for project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#list-screenshots-tags | ||
*/ | ||
@@ -95,3 +99,3 @@ listScreenshotsTags(options: ListScreenshotsTags, config?: CommonConfig): Promise<ListScreenshotsTagsResult>; | ||
* Upload a new screenshot for the project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#create-a-new-screenshot | ||
*/ | ||
@@ -101,3 +105,3 @@ postScreenshots(options: PostScreenshots, config?: CommonConfig): Promise<PostScreenshotsResult>; | ||
* Change image data of existing screenshot. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#update-the-image-of-an-existing-screenshot | ||
*/ | ||
@@ -107,8 +111,22 @@ postScreenshot(options: PostScreenshot, config?: CommonConfig): Promise<PostScreenshotResult>; | ||
* Change existing screenshot (metadata). | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#update-an-existing-screenshot | ||
*/ | ||
putScreenshot(options: PutScreenshot, config?: CommonConfig): Promise<PutScreenshotResult>; | ||
/** | ||
* Delete existing screenshot | ||
* @see https://localazy.com/docs/api/screenshot-management#delete-a-screenshot | ||
*/ | ||
deleteScreenshot(options: DeleteScreenshot, config?: CommonConfig): Promise<DeleteScreenshotResult>; | ||
/** | ||
* Update an existing key | ||
* @see https://localazy.com/docs/api/source-keys#update-source-key | ||
*/ | ||
updateKey(options: UpdateKey, config?: CommonConfig): Promise<UpdateKeyResult>; | ||
/** | ||
* Delete an existing key | ||
* @see https://localazy.com/docs/api/source-keys#delete-source-key | ||
*/ | ||
deleteKey(options: DeleteKey, config?: CommonConfig): Promise<DeleteKeyResult>; | ||
} | ||
export default function LocalazyServiceFactory(options: Constructor): LocalazyService; | ||
export {}; |
@@ -73,3 +73,3 @@ "use strict"; | ||
* List projects related to the project token. | ||
* @see https://localazy.com/docs/api/list-projects | ||
* @see https://localazy.com/docs/api/projects#list-projects | ||
*/ | ||
@@ -96,3 +96,3 @@ Object.defineProperty(LocalazyService.prototype, "listProjects", { | ||
* Import content into Localazy. | ||
* @see https://localazy.com/docs/api/import | ||
* @see https://localazy.com/docs/api/import#import-content-to-a-project | ||
*/ | ||
@@ -120,3 +120,3 @@ Object.defineProperty(LocalazyService.prototype, "import", { | ||
* Retrieve list of available file formats and related options. | ||
* @see https://localazy.com/docs/api/import#retrieve-a-list-of-available-file-types | ||
* @see https://localazy.com/docs/api/import#list-available-file-types | ||
*/ | ||
@@ -141,3 +141,3 @@ Object.defineProperty(LocalazyService.prototype, "listFormats", { | ||
* List Localazy files. | ||
* @see https://localazy.com/docs/api/files | ||
* @see https://localazy.com/docs/api/files#list-files-in-project | ||
*/ | ||
@@ -164,3 +164,3 @@ Object.defineProperty(LocalazyService.prototype, "listFiles", { | ||
* Returns the given file contents. | ||
* @see https://localazy.com/docs/api/files | ||
* @see https://localazy.com/docs/api/files#list-file-content | ||
*/ | ||
@@ -210,3 +210,3 @@ Object.defineProperty(LocalazyService.prototype, "getFileContents", { | ||
* Retrieve list of webhooks for project. | ||
* @see https://localazy.com/docs/api/webhooks | ||
* @see https://localazy.com/docs/api/webhooks-api#list-webhooks-configuration | ||
*/ | ||
@@ -233,3 +233,3 @@ Object.defineProperty(LocalazyService.prototype, "listWebhooks", { | ||
* Store a new webhooks configuration for the project. | ||
* @see https://localazy.com/docs/api/webhooks | ||
* @see https://localazy.com/docs/api/screenshot-management#create-a-new-screenshot | ||
*/ | ||
@@ -257,3 +257,3 @@ Object.defineProperty(LocalazyService.prototype, "postWebhooks", { | ||
* Retrieve list of screenshots for project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#list-screenshots | ||
*/ | ||
@@ -280,3 +280,3 @@ Object.defineProperty(LocalazyService.prototype, "listScreenshots", { | ||
* Retrive list of screenshots tags for project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#list-screenshots-tags | ||
*/ | ||
@@ -303,3 +303,3 @@ Object.defineProperty(LocalazyService.prototype, "listScreenshotsTags", { | ||
* Upload a new screenshot for the project. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#create-a-new-screenshot | ||
*/ | ||
@@ -327,3 +327,3 @@ Object.defineProperty(LocalazyService.prototype, "postScreenshots", { | ||
* Change image data of existing screenshot. | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#update-the-image-of-an-existing-screenshot | ||
*/ | ||
@@ -351,3 +351,3 @@ Object.defineProperty(LocalazyService.prototype, "postScreenshot", { | ||
* Change existing screenshot (metadata). | ||
* @see https://localazy.com/docs/api/screenshots | ||
* @see https://localazy.com/docs/api/screenshot-management#update-an-existing-screenshot | ||
*/ | ||
@@ -373,2 +373,6 @@ Object.defineProperty(LocalazyService.prototype, "putScreenshot", { | ||
}); | ||
/** | ||
* Delete existing screenshot | ||
* @see https://localazy.com/docs/api/screenshot-management#delete-a-screenshot | ||
*/ | ||
Object.defineProperty(LocalazyService.prototype, "deleteScreenshot", { | ||
@@ -392,2 +396,47 @@ enumerable: false, | ||
}); | ||
/** | ||
* Update an existing key | ||
* @see https://localazy.com/docs/api/source-keys#update-source-key | ||
*/ | ||
Object.defineProperty(LocalazyService.prototype, "updateKey", { | ||
enumerable: false, | ||
configurable: true, | ||
writable: true, | ||
value: function (options, config) { | ||
if (config === void 0) { config = {}; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
var projectId, keyId, payload; | ||
return __generator(this, function (_a) { | ||
projectId = options.projectId, keyId = options.keyId, payload = __rest(options, ["projectId", "keyId"]); | ||
return [2 /*return*/, api_1.default.put({ | ||
url: "".concat(config.baseUrl || this.baseUrl, "/projects/").concat(projectId, "/keys/").concat(keyId), | ||
projectToken: config.projectToken || this.projectToken, | ||
options: payload, | ||
})]; | ||
}); | ||
}); | ||
} | ||
}); | ||
/** | ||
* Delete an existing key | ||
* @see https://localazy.com/docs/api/source-keys#delete-source-key | ||
*/ | ||
Object.defineProperty(LocalazyService.prototype, "deleteKey", { | ||
enumerable: false, | ||
configurable: true, | ||
writable: true, | ||
value: function (options, config) { | ||
if (config === void 0) { config = {}; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
var projectId, keyId; | ||
return __generator(this, function (_a) { | ||
projectId = options.projectId, keyId = options.keyId; | ||
return [2 /*return*/, api_1.default.delete({ | ||
url: "".concat(config.baseUrl || this.baseUrl, "/projects/").concat(projectId, "/keys/").concat(keyId), | ||
projectToken: config.projectToken || this.projectToken, | ||
})]; | ||
}); | ||
}); | ||
} | ||
}); | ||
return LocalazyService; | ||
@@ -394,0 +443,0 @@ }()); |
@@ -17,2 +17,5 @@ import LocFile from './loc-file'; | ||
filterSource?: boolean; | ||
/** Tell the server to deprecate any key missing in this upload batch | ||
* Default: 'none' */ | ||
deprecate?: 'none' | 'file' | 'project'; | ||
/** The structure of files and strings to be imported. */ | ||
@@ -19,0 +22,0 @@ files: LocFile[]; |
{ | ||
"name": "@localazy/ts-api", | ||
"version": "1.0.11-alpha.0", | ||
"version": "1.0.11", | ||
"description": "This is a Typescript library facilitating usage of Localazy's API.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
73578
126
1225
1