> ## Documentation Index
> Fetch the complete documentation index at: https://docs.series.hr/llms.txt
> Use this file to discover all available pages before exploring further.

# Unclaim Ticket

> Unclaim a previously claimed ticket

<Warning>
  **Requires Premium or Enterprise subscription**
</Warning>

## Overview

Unclaim a previously claimed ticket. Removes the claim and allows another staff member to claim it.

**Important Notes:**

* A system message is automatically added when unclaiming
* The ticket status remains unchanged

## Path Parameters

<ParamField path="ticketId" type="string" required>
  Ticket ID
</ParamField>

## Request Body

<ParamField body="staffUserId" type="integer" required>
  UserId of the staff member unclaiming the ticket
</ParamField>

## Response

<ResponseField name="success" type="boolean">
  Whether the request was successful
</ResponseField>

<ResponseField name="data" type="object">
  <Expandable title="properties">
    <ResponseField name="message" type="string">
      Success message
    </ResponseField>
  </Expandable>
</ResponseField>

## Example

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST "https://api.series.hr/tickets/TICKET-1234567890-ABCD/unclaim" \
    -H "apikey: YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "staffUserId": 987654321
    }'
  ```

  ```typescript TypeScript theme={null}
  const response = await fetch('https://api.series.hr/tickets/TICKET-1234567890-ABCD/unclaim', {
    method: 'POST',
    headers: {
      'apikey': 'YOUR_API_KEY',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      staffUserId: 987654321
    })
  });

  const data = await response.json();
  ```

  ```lua Lua (Roblox) theme={null}
  local HttpService = game:GetService("HttpService")

  local response = HttpService:RequestAsync({
      Url = "https://api.series.hr/tickets/TICKET-1234567890-ABCD/unclaim",
      Method = "POST",
      Headers = {
          ["apikey"] = "YOUR_API_KEY",
          ["Content-Type"] = "application/json"
      },
      Body = HttpService:JSONEncode({
          staffUserId = 987654321
      })
  })

  local data = HttpService:JSONDecode(response.Body)
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://api.series.hr/tickets/TICKET-1234567890-ABCD/unclaim',
      headers={
          'apikey': 'YOUR_API_KEY',
          'Content-Type': 'application/json'
      },
      json={'staffUserId': 987654321}
  )

  data = response.json()
  ```
</CodeGroup>

## Response Example

```json theme={null}
{
  "success": true,
  "data": {
    "message": "Ticket unclaimed successfully"
  }
}
```

## Error Responses

<AccordionGroup>
  <Accordion title="400 - Not Claimed">
    ```json theme={null}
    {
      "success": false,
      "error": {
        "code": 400,
        "message": "Ticket is not claimed"
      }
    }
    ```
  </Accordion>

  <Accordion title="403 - Premium Required">
    ```json theme={null}
    {
      "success": false,
      "error": {
        "code": 403,
        "message": "Tickets module requires a Premium or Enterprise subscription"
      }
    }
    ```
  </Accordion>

  <Accordion title="404 - Ticket Not Found">
    ```json theme={null}
    {
      "success": false,
      "error": {
        "code": 404,
        "message": "Ticket not found"
      }
    }
    ```
  </Accordion>
</AccordionGroup>

## Rate Limit

**25 requests per second** per API key


## OpenAPI

````yaml POST /tickets/{ticketId}/unclaim
openapi: 3.0.0
info:
  title: Series API
  version: 1.0.0
  description: >-
    Series API — a free REST API by Sailboat Games, LLC that lets Roblox
    communities programmatically manage workspaces, staff, sessions, time-off
    and activity data.
  contact:
    name: Sailboat Games, LLC.
    email: admin@sailboatgames.com
servers:
  - url: https://api.series.hr
    description: Production API
security:
  - ApiKeyAuth: []
paths:
  /tickets/{ticketId}/unclaim:
    post:
      tags:
        - Tickets
      summary: Unclaim ticket
      description: >-
        Unclaim a previously claimed ticket. Requires Premium or Enterprise
        subscription.
      parameters:
        - name: ticketId
          in: path
          required: true
          schema:
            type: string
          description: Ticket ID
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - staffUserId
              properties:
                staffUserId:
                  type: integer
                  description: UserId of the staff member unclaiming the ticket
      responses:
        '200':
          description: Ticket unclaimed successfully
        '400':
          description: Ticket is not claimed
        '401':
          description: API key is required
        '403':
          description: Tickets module not enabled or Premium required
        '404':
          description: Ticket not found
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: apikey
      description: >-
        Pass your API key in the `apikey` header. Alternatively, the `x-api-key`
        header is also accepted.

````