---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../modules.md) / [cli](../index.md) / B2COperationContext

# Interface: B2COperationContext

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:67](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L67)

Context provided to lifecycle hooks for a B2C operation.

Includes the B2CInstance so plugins can access API clients and configuration
without needing to construct their own instance.

## Properties

### instance

> **instance**: [`B2CInstance`](../../instance/classes/B2CInstance.md)

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:73](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L73)

B2C instance with configured API clients

***

### metadata

> **metadata**: `Record`\<`string`, `unknown`\>

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:77](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L77)

Operation-specific metadata (jobId, codeVersion, parameters, etc.)

***

### operationId

> **operationId**: `string`

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:71](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L71)

Unique ID for this operation invocation

***

### operationType

> **operationType**: [`B2COperationType`](../type-aliases/B2COperationType.md)

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:69](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L69)

Type of operation being executed

***

### startTime

> **startTime**: `number`

Defined in: [packages/b2c-tooling-sdk/src/cli/lifecycle.ts:75](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/2feab01f654eec77c6d702777ec2818472f131f1/packages/b2c-tooling-sdk/src/cli/lifecycle.ts#L75)

Start timestamp
