---
schema_version: "1"
id: e5a59ddcd6e9682ae8d988c42da218c153607b7acb9f243755ee4ee261260be6
title: InventoryReservation
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/object_reference/sforce_api_objects_inventoryreservation.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/sforce_api_objects_inventoryreservation.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: 02ee6eae9329d97bb0bcbbaacdddd4376fa006ecad0ef71e0399d53103a939eb
description: Stores information about the status of cart inventory reservations in B2B and D2C Commerce. This object is available in API version 60.0 and later.
---
# InventoryReservation

Stores information about the status of cart inventory reservations in B2B and D2C Commerce. This object is available in API version 60.0 and later.

This object only applies to cart inventory reservation APIs in B2B and D2C Commerce. It isn't related to inventory reservation Connect APIs used with Omnichannel Inventory and Order Management.

If your org is using Omnichannel Inventory as its inventory system, the inventory reservation record related to the cart also represents a reservation in Omnichannel Inventory. If the org uses a different inventory system, the inventory reservation record related to the cart represents a reservation in that inventory system.

## Supported Calls

create(), delete(), describeLayout(), describeSObjects(), getDeleted(), getUpdated(), query(), retrieve(), undelete(), update(), upsert()

## Special Access Rules

This object is available only if a B2B Commerce, D2C Commerce, B2C Commerce, or Salesforce Order Management license is enabled.

## Fields

| Field | Details |
| --- | --- |
| ErrorCode | 
Type

string

Properties

Create, Filter, Group, Nillable, Sort, Update

Description

The error code if the reservation isn’t successful.



 |
| ErrorMessage | 

Type

textarea

Properties

Create, Nillable, Update

Description

If an error occurred, this field contains the error message.



 |
| InventoryReservationName | 

Type

string

Properties

Autonumber, Defaulted on create, Filter, idLookup, Sort

Description

Name of the inventory reservation (autogenerated, for example: PIR-0033).



 |
| IsAsyncOperationInProgress | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

Indicates if there’s an async operation in progress that could affect the reservation.

The default value is false.



 |
| IsSuccess | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

Indicates whether the most recent inventory system operation was successful.

The default value is false.



 |
| LastReferencedDate | 

Type

dateTime

Properties

Filter, Nillable, Sort

Description

The timestamp when the current user last accessed this record indirectly, for example, through a list view or related record.



 |
| LastViewedDate | 

Type

dateTime

Properties

Filter, Nillable, Sort

Description

The timestamp when the current user last viewed this record or list view. If this value is null, the user could have only accessed this record or list view (LastReferencedDate) but not viewed it.



 |
| OwnerId | 

Type

reference

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

The user who owns the inventory reservation.

This field is a polymorphic relationship field.

Relationship Name

Owner

Relationship Type

Lookup

Refers To

Group, User



 |
| ReservationDate | 

Type

dateTime

Properties

Create, Filter, Sort, Update

Description

The timestamp when the inventory reservation was created.



 |
| ReservationDurationInSeconds | 

Type

int

Properties

Create, Filter, Group, Nillable, Sort, Update

Description

The total duration of the inventory reservation in seconds.



 |
| ReservationIdentifier | 

Type

string

Properties

Create, Filter, Group, idLookup, Nillable, Sort, Update

Description

The unique identifier (text value) for the reservation.



 |
| ReservationSourceId | 

Type

reference

Properties

Create, Filter, Group, Nillable, Sort, Update

Description

The ID of the entity associated with the inventory reservation.

This field is a polymorphic relationship field.

Relationship Name

ReservationSource

Relationship Type

Lookup

Refers To

Export\_FOI\_\_c, WebCart



 |

## Associated Objects

This object has these associated objects. If the API version isn’t specified, they’re available in the same API versions as this object. Otherwise, they’re available in the specified API version and later.

[InventoryReservationOwnerSharingRule](https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/sforce_api_associated_objects_ownersharingrule.htm "StandardObjectNameOwnerSharingRule is the model for all owner sharing rule objects associated with standard objects. These objects represent a rule for sharing a standard object with users other than the owner.")

Sharing rules are available for the object.

[InventoryReservationShare](https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/sforce_api_associated_objects_share.htm "StandardObjectNameShare is the model for all share objects associated with standard objects. These objects represent a sharing entry on the standard object.")

Sharing is available for the object.