Get the jobs folder
const url = 'http://127.0.0.1:8765/api/jobs-folder';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url http://127.0.0.1:8765/api/jobs-folderThe jobs folder: one folder per application, where a job’s resume.md is kept. One visible folder (default ~/Documents/GigAI/jobs; a GigAI home other than ~/.gigai defaults to <home>/jobs) with one folder per application: <company>/<role>/resume.md is the job’s picked resume as clean markdown. <company> is the posting’s company name and <role> its title, as lowercase ASCII with hyphens and no date; two roles at one company are two folders, and when two postings would get the same folder the later one’s name ends in a short id. The same job always keeps its folder. cover-letter.md and interview/ are the names of the cover letter and the interview package there; GigAI never creates either one empty. The folder never holds a name or contact details, and never a PDF: a generated PDF is saved only where the user saves it. GigAI replaces resume.md only when it is exactly what GigAI last wrote (otherwise the new resume is written beside it as resume-2.md). source is default or setting. job is null when GigAI has made no folder for the job, else {path, shown, relative, files: {resume}}: paths and a file name, never a file’s contents. One index lookup: the folder is never scanned.
Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Optional (0.1.11.9: the job names its folder); taken with job_identity and picks nothing.
The job: adds job, that job’s own folder and the names of its files.
Responses
Section titled “Responses”Success.
object
Example
{ "default": "~/Documents/GigAI/jobs", "exists": true, "path": "/home/you/Documents/GigAI/jobs", "schema_version": "scout-jobs-folder-response:1", "shown": "~/Documents/GigAI/jobs", "source": "default"}Forbidden / forbidden_origin: loopback peer and Host 127.0.0.1:<port> or localhost:<port> only (Origin too on writes).
object
object
Examplegenerated
{ "error": { "allowed_keys": [ "example" ], "code": "example", "message": "example" }}Target_unavailable
object
object
Example
{ "error": { "code": "target_unavailable", "message": "..." }}Unknown_key, invalid_value
object
object
Example
{ "error": { "code": "unknown_key", "message": "..." }}