---
title: "execute an RPC of a workflow"
method: POST
path: "/api/v1/workflow/rpc"
---

# execute an RPC of a workflow

`POST /api/v1/workflow/rpc`

## Request body

- WorkflowRpcRequest
  - `workflowId` string, required
  - `workflowRunId` string
  - `rpcName` string, required
  - `input` EncodedObject
    - `extStoreId` string
    - `extPath` string
    - `encoding` string
    - `data` string
  - `searchAttributesLoadingPolicy` PersistenceLoadingPolicy
    - `persistenceLoadingType` 'LOAD_ALL_WITHOUT_LOCKING' | 'LOAD_PARTIAL_WITHOUT_LOCKING' | 'LOAD_PARTIAL_WITH_EXCLUSIVE_LOCK' | 'LOAD_NONE' | 'LOAD_ALL_WITH_PARTIAL_LOCK'
    - `partialLoadingKeys` string[]
    - `lockingKeys` string[]
    - `useKeyAsPrefix` boolean
    - `lazyLoadingLargeDataAttributes` boolean
  - `dataAttributesLoadingPolicy` PersistenceLoadingPolicy
    - `persistenceLoadingType` 'LOAD_ALL_WITHOUT_LOCKING' | 'LOAD_PARTIAL_WITHOUT_LOCKING' | 'LOAD_PARTIAL_WITH_EXCLUSIVE_LOCK' | 'LOAD_NONE' | 'LOAD_ALL_WITH_PARTIAL_LOCK'
    - `partialLoadingKeys` string[]
    - `lockingKeys` string[]
    - `useKeyAsPrefix` boolean
    - `lazyLoadingLargeDataAttributes` boolean
  - `timeoutSeconds` integer
  - `useMemoForDataAttributes` boolean
  - `searchAttributes` SearchAttributeKeyAndType[]
    - `key` string
    - `valueType` 'KEYWORD' | 'TEXT' | 'DATETIME' | 'INT' | 'DOUBLE' | 'BOOL' | 'KEYWORD_ARRAY'

## Response `200`

successful operation

- WorkflowRpcResponse
  - `output` EncodedObject
    - `extStoreId` string
    - `extPath` string
    - `encoding` string
    - `data` string

## Other responses

- `400` — Invalid input
- `420` — RPC execution error
- `450` — RPC acquire locking failure

## Changes

> 50 revisions in range; 1 could not be searched.

- **2024-05-14** `90548a4540ab` — 4 info
  - added the new optional request property `dataAttributesLoadingPolicy/useKeyAsPrefix`
  - added the new optional request property `searchAttributesLoadingPolicy/useKeyAsPrefix`
  - added the new `LOAD_ALL_WITH_PARTIAL_LOCK` enum value to the request property `dataAttributesLoadingPolicy/persistenceLoadingType`
  - added the new `LOAD_ALL_WITH_PARTIAL_LOCK` enum value to the request property `searchAttributesLoadingPolicy/persistenceLoadingType`
- **2023-08-25** `8c4dd5f2b718` — 1 info
  - added the non-success response with the status `450`
- **2023-08-05** `3944ca03b15a` — 2 info
  - added the new `LOAD_NONE` enum value to the request property `dataAttributesLoadingPolicy/persistenceLoadingType`
  - added the new `LOAD_NONE` enum value to the request property `searchAttributesLoadingPolicy/persistenceLoadingType`
- **2023-07-05** `b341064dfc4b` — 2 warning
  - added the new `LONG_POLL_TIME_OUT_SUB_STATUS` enum value to the `subStatus` response property for the response status `400`
  - added the new `LONG_POLL_TIME_OUT_SUB_STATUS` enum value to the `subStatus` response property for the response status `420`
- **2023-05-31** `ca16607cb0f3` — 3 info
  - added the new optional request property `searchAttributes`
  - added the new optional request property `useMemoForDataAttributes`
  - added the non-success response with the status `420`

[Full history](https://skmtc.dev/indeedeng/apis/workflow-apis/changes/api/v1/workflow/rpc/post.md)

---

[API](https://skmtc.dev/indeedeng/apis/workflow-apis.md) · [All operations](https://skmtc.dev/indeedeng/apis/workflow-apis/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/indeedeng/workflow-apis/revisions/fe9c7606824c/schema)
