> For the complete documentation index, see [llms.txt](https://frinn.gitbook.io/custom-machinery-1.21/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://frinn.gitbook.io/custom-machinery-1.21/mod-integrations/kubejs/recipes/experience.md).

# Experience

Use the experience requirement in a KubeJS recipe

**Use one of these methods to add an** [**experience requirement**](/custom-machinery-1.21/recipes/requirements/experience.md) **to the recipe.**

```javascript
.requireXp(amount)
.requireXpPerTick(amount)

.produceXp(amount)
.produceXpPerTick(amount)

.requireLevel(amount)
.requireLevelPerTick(amount)

.produceLevel(amount)
.produceLevelPerTick(amount)
```

* The `amount` param must be a positive integer.

### Example

The following recipe will produce 3xp points:&#x20;

```javascript
ServerEvents.recipes(event => {

  event.recipes.custommachinery.custom_machine("custommachinery:power_crusher", 100)
  .produceXp(3)
  
})
```
