---
title: "insertUserArticle"
slug: "api/basket/operations/insertuserarticle"
sidebar:
  order: 431
---

<a id="ref-6116d8b64dce"></a>
<a id="ref-022e46b74df4"></a>
<a id="ref-d16d4df505b4"></a>

## Synopsis

```text
void insertUserArticle(SessionId sessionId,
    BItemId fatherId,
    BItemId beforeId,
    DisplayText shortText)
throws BasketServiceFault;
```

See also: [SessionId](/pCon/configuratorOnline/specs/api/session/types/sessionid#ref-02e397c8fdb4), [BItemId](/pCon/configuratorOnline/specs/api/basket/types/bitemid#ref-bccb6c926e5b), [`DisplayText`](/pCon/configuratorOnline/specs/api/basket/types/displaytext-basket#ref-b19f0939e15a), [BasketServiceFault](/pCon/configuratorOnline/specs/api/basket/faults/basketservicefault#ref-d5adb74faa1b)

The `insertUserArticle` operation inserts a new user article item (also known as manual article) into the basket item tree maintained by the basket service for the session identified by the `sessionId` parameter.

The `fatherId` parameter, if not the null-UUID, must identify the basket item that will become the parent of the new OFML article item. If `fatherId` is the null-UUID (§[UUID](/pCon/configuratorOnline/specs/guide/web-service-interfaces/common-type-definitions/uuid#ref-2a898bc98aaf)), the root item of the basket item tree will be used as the parent item.

The `beforeId` parameter, if not the null-UUID, must identify an existing basket item. If this item is a descendant of the basket item that has been selected as the parent of the newly inserted item, then the new item will be inserted in front of the parent’s child which is either equal to the item identified by `beforeId`, or an ancestor of this item. Otherwise (if `beforeId` is a null-UUID, or if the basket item identified by `beforeId` is not a descendant of the parent item) the new item will be inserted as the last child of the parent item.

The parameter `shortText` should contain the short description of the article.

The inserted basket item is of type `UserArticle` (§[BasketItemType](/pCon/configuratorOnline/specs/api/basket/types/basketitemtype#ref-5d3667cadff0)). Additional properties of the newly inserted user article item may be set using the `setItemProperties` operation (§[setItemProperties](/pCon/configuratorOnline/specs/api/basket/operations/setitemproperties#ref-34e417ae27ba)).

A [`BasketServiceFault`](/pCon/configuratorOnline/specs/api/basket/faults/basketservicefault) is returned if any of the following conditions occurs:

- The `sessionId` parameter is not a valid string representation of an UUID or does not represent an open session.

- Either the `fatherId` or `beforeId` parameter does not represent an UUID.

- Either the `fatherId` or `beforeId` parameter does not identify a basket item and is not the null-UUID.

- The basket item identified by the `fatherId` parameter does not permit child items.

- There was some error during the actual process of inserting the user article item.
