Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/tech-dipesh/yeti-Jobs/llms.txt

Use this file to discover all available pages before exploring further.

The Companies API manages employer profiles on the Yeti Jobs platform. Administrators can register new companies and upload logos (stored in Supabase Storage); company employees can update their profile, view a real-time dashboard of jobs, applications, and follower counts, and browse their applicant pipeline. Job seekers can browse all companies, follow or unfollow specific organisations, and view company-specific job listings. All endpoints in this group require a valid token cookie — authUserMiddleware is applied at the router level. Write operations additionally require the company-employee role and ownership of the target record.

GET /api/v1/companies/all

Returns a paginated list of all registered companies, each including an aggregated job_count.
Requires authentication (token cookie).
page
integer
Page number (default: 1).
limit
integer
Number of companies per page (default: 5).
curl -s "https://yeti-jobs.onrender.com/api/v1/companies/all?page=1&limit=5" \
  --cookie 'token=JWT_TOKEN'
{
  "message": [
    {
      "uid": "c1d2e3f4-0000-1111-2222-aabbccddeeff",
      "name": "Acme Corp",
      "description": "We build world-class software products that delight customers.",
      "website": "https://acme.example.com",
      "location": "San Francisco, CA",
      "founded_year": 2010,
      "logo_url": "https://cdn.example.com/logos/acme.png",
      "job_count": "12"
    }
  ],
  "limit": "5",
  "page": "1",
  "total": "38"
}

POST /api/v1/companies/new

Creates a new company profile. The company logo must be uploaded as a file; it is stored in Supabase Storage and the public URL is saved to the logo_url column. Send the request as multipart/form-data.
Requires authentication. In production this endpoint is typically used by administrators to register companies before assigning employees.
name
string
required
Company name. Minimum 2 characters. Must be unique (case-insensitive).
description
string
required
Company description. 25–250 characters.
website
string
required
Full URL of the company website, e.g. https://acme.example.com.
location
string
required
Headquarters location. Minimum 3 characters.
founded_year
integer
required
Four-digit founding year (1900–2026).
Logo image file. Form field name must be company_logo.
curl -s -X POST https://yeti-jobs.onrender.com/api/v1/companies/new \
  --cookie 'token=JWT_TOKEN' \
  -F "name=Acme Corp" \
  -F "description=We build world-class software products that delight our customers worldwide." \
  -F "website=https://acme.example.com" \
  -F "location=San Francisco, CA" \
  -F "founded_year=2010" \
  -F "company_logo=@/path/to/logo.png"
{
  "message": "New Company Added"
}

GET /api/v1/companies/dashboard

Returns aggregate statistics for the authenticated employee’s company: total jobs posted, total applications received, open jobs, total employees, and total followers.
Requires authentication and the company-employee role (company_id must be set on the user record).
curl -s https://yeti-jobs.onrender.com/api/v1/companies/dashboard \
  --cookie 'token=JWT_TOKEN'
{
  "message": {
    "total_jobs": "24",
    "total_followers": "310",
    "total_applications": "87",
    "open_jobs": "9",
    "total_employees": "5"
  }
}

GET /api/v1/companies/followers

Returns the full user records for every person following the authenticated employee’s company.
Requires authentication and the company-employee role.
curl -s https://yeti-jobs.onrender.com/api/v1/companies/followers \
  --cookie 'token=JWT_TOKEN'
{
  "message": [
    {
      "uid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "fname": "Jane",
      "lname": "Doe",
      "email": "jane.doe@example.com",
      "role": "guest",
      "profile_pic_url": "https://cdn.example.com/profiles/jane.jpg"
    }
  ]
}

GET /api/v1/companies/:id

Returns the full profile of a single company. For guest-role users the response additionally includes an is_followed boolean indicating whether the caller follows this company.
Requires authentication (token cookie). If the caller has the guest role the response includes an is_followed flag.
id
string
required
UUID of the company.
curl -s https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff \
  --cookie 'token=JWT_TOKEN'
{
  "message": {
    "uid": "c1d2e3f4-0000-1111-2222-aabbccddeeff",
    "name": "Acme Corp",
    "description": "We build world-class software products that delight our customers worldwide.",
    "website": "https://acme.example.com",
    "location": "San Francisco, CA",
    "founded_year": 2010,
    "logo_url": "https://cdn.example.com/logos/acme.png",
    "is_followed": false
  }
}

PUT /api/v1/companies/:id

Replaces a company’s profile fields. All fields are required.
Requires authentication, the company-employee role, and ownership of the company record.
id
string
required
UUID of the company to update.
name
string
required
Company name (minimum 2 characters).
description
string
required
Company description. 25–250 characters.
website
string
required
Company website URL.
location
string
required
Headquarters location (minimum 3 characters).
founded_year
integer
required
Four-digit founding year (1900–2026).
curl -s -X PUT https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff \
  --cookie 'token=JWT_TOKEN' \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Acme Corporation",
    "description": "We build world-class software products that delight our customers worldwide.",
    "website": "https://acmecorp.example.com",
    "location": "San Francisco, CA",
    "founded_year": 2010
  }'
{
  "message": {
    "uid": "c1d2e3f4-0000-1111-2222-aabbccddeeff",
    "name": "Acme Corporation",
    "description": "We build world-class software products that delight our customers worldwide.",
    "website": "https://acmecorp.example.com",
    "location": "San Francisco, CA",
    "founded_year": 2010
  }
}

DELETE /api/v1/companies/:id

Permanently deletes a company record and all its associated jobs, applications, and follow relationships.
Requires authentication, the company-employee role, and ownership of the company record.
id
string
required
UUID of the company to delete.
curl -s -X DELETE https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff \
  --cookie 'token=JWT_TOKEN'
{
  "message": "Id Deleted Succssfully"
}

POST /api/v1/companies/:id/follow

Adds the authenticated job seeker to the company’s follower list. A user cannot follow the same company more than once.
Requires authentication and the guest (job seeker) role.
id
string
required
UUID of the company to follow.
curl -s -X POST https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff/follow \
  --cookie 'token=JWT_TOKEN'
{
  "message": "Succssfully Followed To Company"
}

DELETE /api/v1/companies/:id/follow

Removes the authenticated job seeker from the company’s follower list.
Requires authentication and the guest (job seeker) role.
id
string
required
UUID of the company to unfollow.
curl -s -X DELETE https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff/follow \
  --cookie 'token=JWT_TOKEN'
{
  "message": "Succssfully Unfollowed a Company"
}

GET /api/v1/companies/:id/employees

Lists all users whose company_id matches the authenticated employee’s company. Returns name, email, education, experience level, resume URL, and profile picture.
Requires authentication and the company-employee role. The company_id is taken from the JWT, not from the path parameter.
id
string
required
UUID of the company (used to scope the query).
curl -s https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff/employees \
  --cookie 'token=JWT_TOKEN'
{
  "message": [
    {
      "full_name": "Alice Recruiter",
      "email": "alice@acme.example.com",
      "experience": "7",
      "education": "Postgraduation",
      "role": "recruiter",
      "resume_url": "https://cdn.example.com/resumes/alice.pdf",
      "profile_pic_url": "https://cdn.example.com/profiles/alice.jpg"
    }
  ]
}

GET /api/v1/companies/:id/jobs

Returns all job listings posted by the specified company, including view counts, open/closed status, and the creator’s user ID.
Requires authentication (token cookie).
id
string
required
UUID of the company.
curl -s https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff/jobs \
  --cookie 'token=JWT_TOKEN'
{
  "message": [
    {
      "uid": "f1e2d3c4-b5a6-7890-abcd-112233445566",
      "title": "Backend Engineer",
      "description": "Design and build scalable REST APIs...",
      "salary": 110000,
      "job_type": "Remote",
      "is_job_open": "active",
      "experience_years": 3,
      "total_job_views": 57,
      "expired_at": "2025-06-30T00:00:00.000Z",
      "created_by": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "company_name": "Acme Corp"
    }
  ]
}

GET /api/v1/companies/:id/applications

Returns all applications across every job belonging to the specified company, joined with applicant contact details and job metadata.
Requires authentication and the company-employee role.
id
string
required
UUID of the company.
curl -s https://yeti-jobs.onrender.com/api/v1/companies/c1d2e3f4-0000-1111-2222-aabbccddeeff/applications \
  --cookie 'token=JWT_TOKEN'
{
  "message": [
    {
      "application_id": "app-uuid-0001",
      "status": "shortlisted",
      "cover_letter": "I am excited to apply for this role...",
      "notice_period": 30,
      "expected_salary": 115000,
      "why_hire": "I have shipped production APIs at scale.",
      "resume_url": "https://cdn.example.com/resumes/jane-doe.pdf",
      "phone_number": "+14155552671",
      "job_title": "Backend Engineer",
      "total_job_views": 57,
      "applicant_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "job_id": "f1e2d3c4-b5a6-7890-abcd-112233445566"
    }
  ]
}

Build docs developers (and LLMs) love