Skip to content

Commit

Permalink
chore(docs): add more logstf documentation, fix labeler (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
c43721 authored Nov 8, 2024
2 parents be028c6 + 901b5ca commit c8b4eea
Show file tree
Hide file tree
Showing 4 changed files with 68 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -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/**"
20 changes: 20 additions & 0 deletions javascript-sdk/logstf/types/endpoints/logSearch.ts
Original file line number Diff line number Diff line change
@@ -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;
Expand Down
25 changes: 25 additions & 0 deletions javascript-sdk/logstf/types/endpoints/logSearchRequest.ts
Original file line number Diff line number Diff line change
@@ -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;
};
18 changes: 18 additions & 0 deletions javascript-sdk/logstf/types/endpoints/logUploadResponse.ts
Original file line number Diff line number Diff line change
@@ -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;
};

0 comments on commit c8b4eea

Please sign in to comment.