From 6c66d1b870d1fad0345dd8aa7f49f05020104c9b Mon Sep 17 00:00:00 2001 From: c43721 Date: Fri, 8 Nov 2024 12:12:39 -0600 Subject: [PATCH 1/3] chore(docs): add documentation, fix labeler --- .github/labeler.yml | 10 ++++---- .../logstf/types/endpoints/logSearch.ts | 20 +++++++++++++++ .../types/endpoints/logSearchRequest.ts | 25 +++++++++++++++++++ .../types/endpoints/logUploadResponse.ts | 18 +++++++++++++ 4 files changed, 68 insertions(+), 5 deletions(-) diff --git a/.github/labeler.yml b/.github/labeler.yml index f7b939d..e734a14 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -1,15 +1,15 @@ sdk: - changed-files: - - any-glob-to-any-file: javscript_sdk/** + - any-glob-to-any-file: ["javscript-sdk/**"] logstf: - changed-files: - - any-glob-to-any-file: logstf/** + - any-glob-to-any-file: "**/logstf/**" etf2l: - changed-files: - - any-glob-to-any-file: etf2l/** + - any-glob-to-any-file: "**etf2l/**" rgl: - changed-files: - - any-glob-to-any-file: rgl/** + - any-glob-to-any-file: "**/rgl/**" demostf: - changed-files: - - any-glob-to-any-file: demostf/** + - any-glob-to-any-file: "**/demostf/**" diff --git a/javascript-sdk/logstf/types/endpoints/logSearch.ts b/javascript-sdk/logstf/types/endpoints/logSearch.ts index 2ed4818..8b18161 100644 --- a/javascript-sdk/logstf/types/endpoints/logSearch.ts +++ b/javascript-sdk/logstf/types/endpoints/logSearch.ts @@ -1,10 +1,30 @@ import type { LogSearchRequest } from "./logSearchRequest.ts"; +/** + * The result of a search request + */ export type LogSearchResponse = { + /** + * A flag that determines the success of the operation + */ success: boolean; + /** + * The number of results + */ results: number; + + /** + * The total number of results + */ total: number; + /** + * The parameters used in the search request + */ parameters: LogSearchRequest; + + /** + * The results + */ logs: [ { id: number; diff --git a/javascript-sdk/logstf/types/endpoints/logSearchRequest.ts b/javascript-sdk/logstf/types/endpoints/logSearchRequest.ts index 444314b..6e20844 100644 --- a/javascript-sdk/logstf/types/endpoints/logSearchRequest.ts +++ b/javascript-sdk/logstf/types/endpoints/logSearchRequest.ts @@ -1,8 +1,33 @@ +/** + * The request to search for logs + */ export type LogSearchRequest = { + /** + * The title of the log + */ title: string | null; + + /** + * The map of the log + */ map: string | null; + + /** + * The steamid of the uploader + */ uploader: string | null; + /** + * The list of steamids that played in the log + */ player: string[] | null; + + /** + * The number of entries to return + */ limit: number; + + /** + * The number of entries to skip + */ offset: number; }; diff --git a/javascript-sdk/logstf/types/endpoints/logUploadResponse.ts b/javascript-sdk/logstf/types/endpoints/logUploadResponse.ts index 0482a94..bb618bd 100644 --- a/javascript-sdk/logstf/types/endpoints/logUploadResponse.ts +++ b/javascript-sdk/logstf/types/endpoints/logUploadResponse.ts @@ -1,6 +1,24 @@ +/** + * The response to an upload request + */ export type LogUploadResponse = { + /** + * A flag that determines whether the request was successful + */ success: boolean; + + /** + * The error of the request + */ error: string; + + /** + * The unique id of the created log + */ log_id: string; + + /** + * The URL of the uploaded log + */ url: string; }; From 5e7a2010b0f661e070bdca1c812c1a19590e33f1 Mon Sep 17 00:00:00 2001 From: c43721 Date: Fri, 8 Nov 2024 12:14:06 -0600 Subject: [PATCH 2/3] fix: move labeler path --- .github/{workflows => }/publish-javscript-sdk.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{workflows => }/publish-javscript-sdk.yml (100%) diff --git a/.github/workflows/publish-javscript-sdk.yml b/.github/publish-javscript-sdk.yml similarity index 100% rename from .github/workflows/publish-javscript-sdk.yml rename to .github/publish-javscript-sdk.yml From 901b5ca683fdd1d7c3c4683c5cb47e46393d3bda Mon Sep 17 00:00:00 2001 From: c43721 Date: Fri, 8 Nov 2024 12:15:39 -0600 Subject: [PATCH 3/3] fix: move workflow --- .github/{ => workflows}/publish-javscript-sdk.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{ => workflows}/publish-javscript-sdk.yml (100%) diff --git a/.github/publish-javscript-sdk.yml b/.github/workflows/publish-javscript-sdk.yml similarity index 100% rename from .github/publish-javscript-sdk.yml rename to .github/workflows/publish-javscript-sdk.yml