***

title: createPaymentParameter
slug: /reference/typescript/agents/function-result/create-payment-parameter
description: Build a parameter entry for the pay() method.
max-toc-depth: 3
---------------------

For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

[pay]: /docs/server-sdks/reference/typescript/agents/function-result/pay

[ref-functionresult]: /docs/server-sdks/reference/typescript/agents/function-result

Static helper that builds a parameter entry for the `parameters` list of
[`pay()`][pay].

## **Parameters**

<ParamField path="name" type="string" required={true} toc={true}>
  Parameter name.
</ParamField>

<ParamField path="value" type="string" required={true} toc={true}>
  Parameter value.
</ParamField>

## **Returns**

`PaymentParameter` — An object with `name` and `value` fields, for use in the `parameters` list of
[`pay()`][pay].

## **Example**

```typescript {3}
import { FunctionResult } from '@signalwire/sdk';

const param = FunctionResult.createPaymentParameter(
  'merchant_id',
  'MERCH_12345',
);
```