# Create a timeline group

Section: Your data › Timeline groups

```
POST https://ba.joexyz.online/api/v1/me/timeline-groups
```

Creates a timeline group and returns it.

**Raid details**

Optional `raid` tags the group, with the same fields as a timeline's except `floor`; `difficulty` is only allowed for `Raid`. Send `null` to clear it. Setting `name` without `autoName` turns off the editor's generated name.

## Authentication

Bearer Token — `Authorization: Bearer <token>` (inherited from folder "Your data")

## Headers

| Name | Value |
| --- | --- |
| `Content-Type` | `application/json` |

## Body

Content type: `application/json`

```json
{
  "name": "Gregorius Lunatic :: Comfy 3-pan",
  "description": "Comfy setups that don't need high invest.",
  "visibility": "public",
  "showCreator": true
}
```

## Example responses

### 201 Created

```json
{
  "data": {
    "id": "jx7fxbrjbwdc9zv20ae97q8sp97rxy45",
    "createdAt": "2025-10-05T15:57:03.790Z",
    "name": "Gregorius Lunatic :: Comfy 3-pan",
    "description": "Comfy setups that don't need high invest.",
    "showCreator": true,
    "timelines": [],
    "visibility": "public"
  }
}
```

### 400 Bad Request

```json
{
  "error": {
    "code": "INVALID_REQUEST",
    "message": "Object is missing the required field `name`."
  }
}
```

## Examples

### cURL

```bash
curl -X POST https://ba.joexyz.online/api/v1/me/timeline-groups \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer {{api_key}}' \
  --data-raw '{
  "name": "Gregorius Lunatic :: Comfy 3-pan",
  "description": "Comfy setups that don'\''t need high invest.",
  "visibility": "public",
  "showCreator": true
}'
```

### JavaScript

```javascript
const response = await fetch("https://ba.joexyz.online/api/v1/me/timeline-groups", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "Authorization": "Bearer {{api_key}}",
  },
  body: JSON.stringify({
    "name": "Gregorius Lunatic :: Comfy 3-pan",
    "description": "Comfy setups that don't need high invest.",
    "visibility": "public",
    "showCreator": true
  }),
});

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

### Python

```python
import requests

url = "https://ba.joexyz.online/api/v1/me/timeline-groups"
headers = {
    "Authorization": "Bearer {{api_key}}",
}
payload = {
    "name": "Gregorius Lunatic :: Comfy 3-pan",
    "description": "Comfy setups that don't need high invest.",
    "visibility": "public",
    "showCreator": True,
}

response = requests.post(url, headers=headers, json=payload)
print(response.json())
```

### Go

```go
package main

import (
	"fmt"
	"io"
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{
  "name": "Gregorius Lunatic :: Comfy 3-pan",
  "description": "Comfy setups that don't need high invest.",
  "visibility": "public",
  "showCreator": true
}`)

	req, err := http.NewRequest("POST", "https://ba.joexyz.online/api/v1/me/timeline-groups", body)
	if err != nil {
		panic(err)
	}
	req.Header.Set("Content-Type", "application/json")
	req.Header.Set("Authorization", "Bearer {{api_key}}")

	res, err := http.DefaultClient.Do(req)
	if err != nil {
		panic(err)
	}
	defer res.Body.Close()

	data, _ := io.ReadAll(res.Body)
	fmt.Println(string(data))
}
```
