@artaio/node-api 1.2.2 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { RestClient } from '../net/RestClient';
|
|
2
2
|
import type { Page } from '../pagination';
|
|
3
|
+
import type { TagsSearch } from '../search';
|
|
3
4
|
import type { Tag } from '../types';
|
|
4
5
|
export type TagCreateBody = Omit<Tag, 'id' | 'created_at' | 'updated_at'>;
|
|
5
6
|
export interface TagCreate {
|
|
@@ -11,7 +12,7 @@ export declare class TagsEndpoint {
|
|
|
11
12
|
private readonly path;
|
|
12
13
|
constructor(artaClient: RestClient);
|
|
13
14
|
getByName(name: Tag['name'], auth?: string): Promise<Tag>;
|
|
14
|
-
list(page?: number, pageSize?: number, auth?: string): Promise<Page<Tag>>;
|
|
15
|
+
list(search?: TagsSearch, page?: number, pageSize?: number, auth?: string): Promise<Page<Tag>>;
|
|
15
16
|
create(payload: TagCreateBody, auth?: string): Promise<Tag>;
|
|
16
17
|
update(name: Tag['name'], payload: Partial<TagCreateBody>, auth?: string): Promise<Tag>;
|
|
17
18
|
}
|
|
@@ -11,10 +11,10 @@ var TagsEndpoint = /** @class */ (function () {
|
|
|
11
11
|
TagsEndpoint.prototype.getByName = function (name, auth) {
|
|
12
12
|
return this.defaultEndpoint.getById(name, auth);
|
|
13
13
|
};
|
|
14
|
-
TagsEndpoint.prototype.list = function (page, pageSize, auth) {
|
|
14
|
+
TagsEndpoint.prototype.list = function (search, page, pageSize, auth) {
|
|
15
15
|
if (page === void 0) { page = 1; }
|
|
16
16
|
if (pageSize === void 0) { pageSize = 20; }
|
|
17
|
-
return this.defaultEndpoint.list({ page: page, page_size: pageSize }, auth);
|
|
17
|
+
return this.defaultEndpoint.list({ page: page, page_size: pageSize, search: search }, auth);
|
|
18
18
|
};
|
|
19
19
|
TagsEndpoint.prototype.create = function (payload, auth) {
|
|
20
20
|
return this.defaultEndpoint.create({ tag: payload }, auth);
|
package/dist/lib/search.d.ts
CHANGED
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@artaio/node-api",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "The Arta Node library provides a seamless integration to Arta API for backend applications using both Typescript or Javascript.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "npm run build:types && tsc -p tsconfig-build.json",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@artaio/node-api",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "The Arta Node library provides a seamless integration to Arta API for backend applications using both Typescript or Javascript.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "npm run build:types && tsc -p tsconfig-build.json",
|