> ## Documentation Index
> Fetch the complete documentation index at: https://upstash-fix-issues-on-docs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Transfer Index

> This endpoint is used to transfer an index to another team.

## Request Parameters

<ParamField path="id" type="string" required>
  The unique ID of the index to be deleted.
</ParamField>

<ParamField body="target_account" type="string" required>
  The ID of the target account. If the target is a team, then use the format `team:<TEAM_ID>`, else if the target is your personal account use the format `<YOUR_EMAIL>`.
</ParamField>

## Response Parameters

`"OK"` on successfull deletion operation.

<RequestExample>
  ```shell curl
  curl -X POST \
    https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer \
    -u 'EMAIL:API_KEY' \
    -d '{"target_account":"team:team-id-1"}'
  ```

  ```javascript JavaScript
  const axios = require('axios');

  const postData = {
    target_account: "team:team-id-1",
  };

  const config = {
    auth: {
      username: 'EMAIL',
      password: 'API_KEY',
    },
    headers: {
      'Content-Type': 'application/json',
    },
  };

  const url = 'https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer';

  axios.post(url, postData, config)
    .then((response) => {
      console.log('Transfer successful:', response.data);
    })
    .catch((error) => {
      console.error('Error:', error);
    });
  ```

  ```python Python
  import requests

  data = '{"target_account":"team:team-id-1"}'

  response = requests.post('https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer', data=data, auth=('EMAIL', 'API_KEY'))
  response.content
  ```

  ```go Go
  client := &http.Client{}
  var data = strings.NewReader(`{
      "target_account":"team:team-id-1",
  }`)
  req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer", data)
  if err != nil {
      log.Fatal(err)
  }
  req.SetBasicAuth("email", "api_key")
  resp, err := client.Do(req)
  if err != nil {
      log.Fatal(err)
  }
  bodyText, err := ioutil.ReadAll(resp.Body)
  if err != nil {
      log.Fatal(err)
  }
  fmt.Printf("%s\n", bodyText);
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK
  "OK"
  ```
</ResponseExample>
