For clean Markdown of any page, append .md to the page URL. For a complete documentation index, see https://docs.ivfprovider.com/ivf-agency-ap-is/egg-donor/cgs-reports/llms.txt. For full documentation content, see https://docs.ivfprovider.com/ivf-agency-ap-is/egg-donor/cgs-reports/llms-full.txt.

# Upload Copy

DELETE http://localhost:8000/api/egg-donors/{id}/cgs-reports/{cgs_report_id}
Content-Type: multipart/form-data

Reference: https://docs.ivfprovider.com/ivf-agency-ap-is/egg-donor/cgs-reports/upload-copy

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: collection
  version: 1.0.0
paths:
  /api/egg-donors/{id}/cgs-reports/{cgs_report_id}:
    delete:
      operationId: upload-copy
      summary: Upload Copy
      tags:
        - subpackage_eggDonor.subpackage_eggDonor/cgsReports
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
        - name: cgs_report_id
          in: path
          required: true
          schema:
            type: string
        - name: Authorization
          in: header
          description: Bearer authentication
          required: true
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/Egg Donor_Cgs Reports_Upload
                  Copy_Response_200
        '422':
          description: Unprocessable Content
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/DeleteApiEgg-donorsIdCgs-reportsCgs_report_idRequestUnprocessableEntityError
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                '':
                  type: string
              required:
                - ''
servers:
  - url: http://localhost:8000
components:
  schemas:
    Egg Donor_Cgs Reports_Upload Copy_Response_200:
      type: object
      properties:
        status:
          type: integer
        message:
          type: string
      required:
        - status
        - message
      title: Egg Donor_Cgs Reports_Upload Copy_Response_200
    ApiEggDonorsIdCgsReportsCgsReportIdDeleteResponsesContentApplicationJsonSchemaErrors:
      type: object
      properties:
        cgs_report_id:
          type: array
          items:
            type: string
        document_title:
          type: array
          items:
            type: string
        report_type:
          type: array
          items:
            type: string
      required:
        - cgs_report_id
        - document_title
        - report_type
      title: >-
        ApiEggDonorsIdCgsReportsCgsReportIdDeleteResponsesContentApplicationJsonSchemaErrors
    DeleteApiEgg-donorsIdCgs-reportsCgs_report_idRequestUnprocessableEntityError:
      type: object
      properties:
        status:
          type: integer
        message:
          type: string
        errors:
          $ref: >-
            #/components/schemas/ApiEggDonorsIdCgsReportsCgsReportIdDeleteResponsesContentApplicationJsonSchemaErrors
      required:
        - status
        - message
        - errors
      title: >-
        DeleteApiEgg-donorsIdCgs-reportsCgs_report_idRequestUnprocessableEntityError
  securitySchemes:
    oauth2Auth:
      type: http
      scheme: bearer

```

## SDK Code Examples

```python Egg Donor_Cgs Reports_Upload Copy_example
import requests

url = "http://localhost:8000/api/egg-donors/20/cgs-reports/3"

payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n"
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "multipart/form-data; boundary=---011000010111000001101001"
}

response = requests.delete(url, data=payload, headers=headers)

print(response.json())
```

```javascript Egg Donor_Cgs Reports_Upload Copy_example
const url = 'http://localhost:8000/api/egg-donors/20/cgs-reports/3';
const form = new FormData();
form.append('', 'string');

const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};

options.body = form;

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Egg Donor_Cgs Reports_Upload Copy_example
package main

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

func main() {

	url := "http://localhost:8000/api/egg-donors/20/cgs-reports/3"

	payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n")

	req, _ := http.NewRequest("DELETE", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Egg Donor_Cgs Reports_Upload Copy_example
require 'uri'
require 'net/http'

url = URI("http://localhost:8000/api/egg-donors/20/cgs-reports/3")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n"

response = http.request(request)
puts response.read_body
```

```java Egg Donor_Cgs Reports_Upload Copy_example
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.delete("http://localhost:8000/api/egg-donors/20/cgs-reports/3")
  .header("Authorization", "Bearer <token>")
  .body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n")
  .asString();
```

```php Egg Donor_Cgs Reports_Upload Copy_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('DELETE', 'http://localhost:8000/api/egg-donors/20/cgs-reports/3', [
  'multipart' => [
    [
        'name' => '',
        'contents' => 'string'
    ]
  ]
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

echo $response->getBody();
```

```csharp Egg Donor_Cgs Reports_Upload Copy_example
using RestSharp;

var client = new RestClient("http://localhost:8000/api/egg-donors/20/cgs-reports/3");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Authorization", "Bearer <token>");
request.AddParameter("undefined", "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Egg Donor_Cgs Reports_Upload Copy_example
import Foundation

let headers = ["Authorization": "Bearer <token>"]
let parameters = [
  [
    "name": "",
    "value": "string"
  ]
]

let boundary = "---011000010111000001101001"

var body = ""
var error: NSError? = nil
for param in parameters {
  let paramName = param["name"]!
  body += "--\(boundary)\r\n"
  body += "Content-Disposition:form-data; name=\"\(paramName)\""
  if let filename = param["fileName"] {
    let contentType = param["content-type"]!
    let fileContent = String(contentsOfFile: filename, encoding: String.Encoding.utf8)
    if (error != nil) {
      print(error as Any)
    }
    body += "; filename=\"\(filename)\"\r\n"
    body += "Content-Type: \(contentType)\r\n\r\n"
    body += fileContent
  } else if let paramValue = param["value"] {
    body += "\r\n\r\n\(paramValue)"
  }
}

let request = NSMutableURLRequest(url: NSURL(string: "http://localhost:8000/api/egg-donors/20/cgs-reports/3")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```