Skip to content

Commit d9cc7ea

Browse files
committed
chore: update Appwrite version
1 parent f2d06b3 commit d9cc7ea

File tree

4 files changed

+0
-86
lines changed

4 files changed

+0
-86
lines changed

docs/examples/functions/list-templates.md

Lines changed: 0 additions & 14 deletions
This file was deleted.

src/models.d.ts

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -168,19 +168,6 @@ export namespace Models {
168168
*/
169169
functions: Function[];
170170
}
171-
/**
172-
* Function Templates List
173-
*/
174-
export type TemplateFunctionList = {
175-
/**
176-
* Total number of templates documents that matched your query.
177-
*/
178-
total: number;
179-
/**
180-
* List of templates.
181-
*/
182-
templates: TemplateFunction[];
183-
}
184171
/**
185172
* Runtimes List
186173
*/

src/services/functions.ts

Lines changed: 0 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -226,50 +226,6 @@ export class Functions extends Service {
226226
'json'
227227
);
228228
}
229-
/**
230-
* List function templates
231-
*
232-
* List available function templates. You can use template details in
233-
* [createFunction](/docs/references/cloud/server-nodejs/functions#create)
234-
* method.
235-
*
236-
* @param {string[]} runtimes
237-
* @param {string[]} useCases
238-
* @param {number} limit
239-
* @param {number} offset
240-
* @throws {AppwriteException}
241-
* @returns {Promise}
242-
*/
243-
async listTemplates(runtimes?: string[], useCases?: string[], limit?: number, offset?: number): Promise<Models.TemplateFunctionList> {
244-
const apiPath = '/functions/templates';
245-
const payload: Payload = {};
246-
247-
if (typeof runtimes !== 'undefined') {
248-
payload['runtimes'] = runtimes;
249-
}
250-
251-
if (typeof useCases !== 'undefined') {
252-
payload['useCases'] = useCases;
253-
}
254-
255-
if (typeof limit !== 'undefined') {
256-
payload['limit'] = limit;
257-
}
258-
259-
if (typeof offset !== 'undefined') {
260-
payload['offset'] = offset;
261-
}
262-
263-
return await this.client.call(
264-
'get',
265-
apiPath,
266-
{
267-
'content-type': 'application/json',
268-
},
269-
payload,
270-
'json'
271-
);
272-
}
273229
/**
274230
* Get function template
275231
*

test/services/functions.test.ts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -97,21 +97,6 @@ describe('Functions service', () => {
9797
});
9898

9999

100-
test('test method listTemplates()', async () => {
101-
const data = {
102-
'total': 5,
103-
'templates': [],};
104-
105-
const stubbedFetch = stub(globalThis, 'fetch', () => Promise.resolve(Response.json(data)));
106-
107-
const response = await functions.listTemplates(
108-
);
109-
110-
assertEquals(response, data);
111-
stubbedFetch.restore();
112-
});
113-
114-
115100
test('test method getTemplate()', async () => {
116101
const data = {
117102
'icon': 'icon-lightning-bolt',

0 commit comments

Comments
 (0)