Update Rows - Excel API
PDF4me Update Rows enables you to update existing rows in Excel documents with table-based or coordinate-based targeting. This API service processes Excel files and modifies cell data using JSON input. The API receives Excel document content and update data through REST API calls, utilizing Base64 encoding for secure transmission. This solution is ideal for data synchronization, report updates, and automated Excel editing workflows.
Authenticating Your API Request
Include your API key in the request to authenticate with the PDF4me REST API.
Key Features
- Row Updates: Modify existing rows with JSON data
- Table or Coordinate Mode: Target by table name or by row/column coordinates
- Type Conversion: Optional automatic conversion of numbers and dates
- Culture Support: Culture-specific date and number parsing
REST API Endpoint
- Method: POST
- Endpoint:
office/ApiV2Excel/ExcelUpdateRows
REST API Parameters
Important: Parameters marked with an asterisk (*) are required. All requests use document, docContent, and updateRowsToExcelAction. Operation-specific parameters (jsonInput, worksheetName, etc.) are properties of the action object.
Required Parameters (root level)
| Parameter | Type | Description | Example |
|---|---|---|---|
| document* | Object | Document reference with Name (Excel file name) | { "Name": "data.xlsx" } |
| docContent* | String (Base64) | Excel document content encoded in Base64 | UEsDBBQABgAIAAAA... |
| updateRowsToExcelAction* | Object | Action configuration. Must contain jsonInput (string) — JSON data for updates | See Payload example below |
Optional Parameters (inside updateRowsToExcelAction)
| Parameter | Type | Description | Example |
|---|---|---|---|
| worksheetName | String | Target worksheet name | Sheet1 |
| tableName | String | Excel table name for table-based mode; empty = coordinate-based | SalesTable |
| excelRowNumber | Number (int) | 1-based row position (table mode) | 5 |
| insertFromRow | Number (int) | 1-based start row (coordinate mode) | 10 |
| insertFromColumn | Number (int) | 1-based start column (coordinate mode) | 1 |
| convertNumericAndDate | Boolean | Automatic type conversion. Default: true | true |
| cultureName | String | Culture for date/number parsing | en-US |
Output
The API returns the Excel document as a Base64-encoded string in JSON format (document, fileName, success, errorMessage).
Request Example
Header
Content-Type: application/json
Authorization: Basic YOUR_BASE64_ENCODED_API_KEY
Payload (Basic)
{
"document": { "Name": "data.xlsx" },
"docContent": "UEsDBBQABgAIAAAA...",
"updateRowsToExcelAction": {
"jsonInput": "[{\"Name\":\"John\",\"Age\":31}]"
}
}