> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.itspropel.com/llms.txt.
> For full documentation content, see https://docs.itspropel.com/llms-full.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.itspropel.com/_mcp/server.

# Complete Chunked Upload

POST https://attachments/upload/%7Bupload_id%7D/complete
Content-Type: application/json

**Complete Chunked Upload**

**Validation Rules:**
- `description` (optional): String, max 500 characters
- `title` (optional): String, max 255 characters
- `tags` (optional): Array, max 10 tags, each tag max 50 characters
- `latitude` (optional): Numeric, between -90 and 90
- `longitude` (optional): Numeric, between -180 and 180
- `captured_at` (optional): Valid date format
- `customer_visible` (optional): Boolean
- `metadata` (optional): Valid JSON object

**Notes:**
- All chunks must be successfully uploaded before calling this endpoint
- This finalizes the upload and creates the media record

Reference: https://docs.itspropel.com/propel-biz/11-work-order/13-work-order-media/04-chunked-upload/complete-chunked-upload

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: PropelBiz
  version: 1.0.0
paths:
  /attachments/upload/%7Bupload_id%7D/complete:
    post:
      operationId: complete-chunked-upload
      summary: Complete Chunked Upload
      description: |-
        **Complete Chunked Upload**

        **Validation Rules:**
        - `description` (optional): String, max 500 characters
        - `title` (optional): String, max 255 characters
        - `tags` (optional): Array, max 10 tags, each tag max 50 characters
        - `latitude` (optional): Numeric, between -90 and 90
        - `longitude` (optional): Numeric, between -180 and 180
        - `captured_at` (optional): Valid date format
        - `customer_visible` (optional): Boolean
        - `metadata` (optional): Valid JSON object

        **Notes:**
        - All chunks must be successfully uploaded before calling this endpoint
        - This finalizes the upload and creates the media record
      tags:
        - >-
          subpackage_11WorkOrder.subpackage_11WorkOrder/13WorkOrderMedia.subpackage_11WorkOrder/13WorkOrderMedia/04ChunkedUpload
      parameters:
        - name: '{{tenant_key_name}}'
          in: header
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/11 Work Order_13 Work Order Media_04
                  Chunked Upload_Complete Chunked Upload_Response_200
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                tags:
                  type: array
                  items:
                    type: string
                title:
                  type: string
                latitude:
                  type: number
                  format: double
                metadata:
                  $ref: >-
                    #/components/schemas/AttachmentsUpload7BuploadId7DCompletePostRequestBodyContentApplicationJsonSchemaMetadata
                longitude:
                  type: number
                  format: double
                captured_at:
                  type: string
                  format: date-time
                description:
                  type: string
                customer_visible:
                  type: boolean
              required:
                - tags
                - title
                - latitude
                - metadata
                - longitude
                - captured_at
                - description
                - customer_visible
servers:
  - url: https:/
components:
  schemas:
    AttachmentsUpload7BuploadId7DCompletePostRequestBodyContentApplicationJsonSchemaMetadata:
      type: object
      properties: {}
      title: >-
        AttachmentsUpload7BuploadId7DCompletePostRequestBodyContentApplicationJsonSchemaMetadata
    11 Work Order_13 Work Order Media_04 Chunked Upload_Complete Chunked Upload_Response_200:
      type: object
      properties: {}
      description: Empty response body
      title: >-
        11 Work Order_13 Work Order Media_04 Chunked Upload_Complete Chunked
        Upload_Response_200

```

## SDK Code Examples

```python
import requests

url = "https://https/attachments/upload/%7Bupload_id%7D/complete"

payload = {
    "tags": ["demo", "video"],
    "title": "Project Demo Video",
    "latitude": 40.7128,
    "longitude": -74.006,
    "captured_at": "2024-01-15T10:00:00Z",
    "description": "Large video file",
    "customer_visible": True
}
headers = {
    "{{tenant_key_name}}": "{{tenant_key_value1}}|{{tenant_key_value2}}",
    "Content-Type": "application/json"
}

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

print(response.json())
```

```javascript
const url = 'https://https/attachments/upload/%7Bupload_id%7D/complete';
const options = {
  method: 'POST',
  headers: {
    '{{tenant_key_name}}': '{{tenant_key_value1}}|{{tenant_key_value2}}',
    'Content-Type': 'application/json'
  },
  body: '{"tags":["demo","video"],"title":"Project Demo Video","latitude":40.7128,"longitude":-74.006,"captured_at":"2024-01-15T10:00:00Z","description":"Large video file","customer_visible":true}'
};

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

```go
package main

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

func main() {

	url := "https://https/attachments/upload/%7Bupload_id%7D/complete"

	payload := strings.NewReader("{\n  \"tags\": [\n    \"demo\",\n    \"video\"\n  ],\n  \"title\": \"Project Demo Video\",\n  \"latitude\": 40.7128,\n  \"longitude\": -74.006,\n  \"captured_at\": \"2024-01-15T10:00:00Z\",\n  \"description\": \"Large video file\",\n  \"customer_visible\": true\n}")

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

	req.Header.Add("{{tenant_key_name}}", "{{tenant_key_value1}}|{{tenant_key_value2}}")
	req.Header.Add("Content-Type", "application/json")

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

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

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

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://https/attachments/upload/%7Bupload_id%7D/complete")

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

request = Net::HTTP::Post.new(url)
request["{{tenant_key_name}}"] = '{{tenant_key_value1}}|{{tenant_key_value2}}'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"tags\": [\n    \"demo\",\n    \"video\"\n  ],\n  \"title\": \"Project Demo Video\",\n  \"latitude\": 40.7128,\n  \"longitude\": -74.006,\n  \"captured_at\": \"2024-01-15T10:00:00Z\",\n  \"description\": \"Large video file\",\n  \"customer_visible\": true\n}"

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

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://https/attachments/upload/%7Bupload_id%7D/complete")
  .header("{{tenant_key_name}}", "{{tenant_key_value1}}|{{tenant_key_value2}}")
  .header("Content-Type", "application/json")
  .body("{\n  \"tags\": [\n    \"demo\",\n    \"video\"\n  ],\n  \"title\": \"Project Demo Video\",\n  \"latitude\": 40.7128,\n  \"longitude\": -74.006,\n  \"captured_at\": \"2024-01-15T10:00:00Z\",\n  \"description\": \"Large video file\",\n  \"customer_visible\": true\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://https/attachments/upload/%7Bupload_id%7D/complete', [
  'body' => '{
  "tags": [
    "demo",
    "video"
  ],
  "title": "Project Demo Video",
  "latitude": 40.7128,
  "longitude": -74.006,
  "captured_at": "2024-01-15T10:00:00Z",
  "description": "Large video file",
  "customer_visible": true
}',
  'headers' => [
    'Content-Type' => 'application/json',
    '{{tenant_key_name}}' => '{{tenant_key_value1}}|{{tenant_key_value2}}',
  ],
]);

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

```csharp
using RestSharp;

var client = new RestClient("https://https/attachments/upload/%7Bupload_id%7D/complete");
var request = new RestRequest(Method.POST);
request.AddHeader("{{tenant_key_name}}", "{{tenant_key_value1}}|{{tenant_key_value2}}");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"tags\": [\n    \"demo\",\n    \"video\"\n  ],\n  \"title\": \"Project Demo Video\",\n  \"latitude\": 40.7128,\n  \"longitude\": -74.006,\n  \"captured_at\": \"2024-01-15T10:00:00Z\",\n  \"description\": \"Large video file\",\n  \"customer_visible\": true\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "{{tenant_key_name}}": "{{tenant_key_value1}}|{{tenant_key_value2}}",
  "Content-Type": "application/json"
]
let parameters = [
  "tags": ["demo", "video"],
  "title": "Project Demo Video",
  "latitude": 40.7128,
  "longitude": -74.006,
  "captured_at": "2024-01-15T10:00:00Z",
  "description": "Large video file",
  "customer_visible": true
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://https/attachments/upload/%7Bupload_id%7D/complete")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
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()
```