---
title: "Upsert URL Group and Endpoint"
method: POST
path: "/v2/topics/{urlGroupName}/endpoints"
tags: ["URL Groups"]
---

# Upsert URL Group and Endpoint

`POST /v2/topics/{urlGroupName}/endpoints`

## Request

- Base URL: `https://qstash-eu-central-1.upstash.io`
- URL: `https://qstash-eu-central-1.upstash.io/v2/topics/{urlGroupName}/endpoints`
- Auth: one of:
  - HTTP bearer
  - API key in query parameter `qstash_token`
- TypeScript: <https://skmtc.dev/upstash/apis/qstash-rest-api/docs/v2/topics/:urlGroupName/endpoints/post.ts> (a function with typed inputs; its response is checked against the schema)

Add an endpoint to a URL Group

## Path parameters

- `urlGroupName` string, required

## Request body

- object
  - `endpoints` object[], required
    - `url` string, required: The URL of the endpoint
    - `name` string: Optional name for the endpoint

## Response `200`

Endpoint(s) added successfully

---

[API](https://skmtc.dev/upstash/apis/qstash-rest-api.md) - [All operations](https://skmtc.dev/upstash/apis/qstash-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/upstash/apis/qstash-rest-api/revisions/0c3b83ef4770?raw)
