---
# System prepended metadata

title: Child Bounties Pallet

---

# Child Bounties Pallet

### Config

1. `pallet_child_bounties` uses the following `pallet_treasury` config types:

- `type RejectOrigin` (`close_child_bounty` and a special case for `unassign_curator`).
- `type OnSlash` (used when a slash occurs).

2. And the following `pallet_bounties` config types:

- `type MaximumReasonLength`
- `type BountyDepositPayoutDelay`

```
impl pallet_child_bounties::Config for Runtime {
	type Event = Event;
	type MaxActiveChildBountyCount = ConstU32<5>;
	type ChildBountyValueMinimum = ChildBountyValueMinimum;
	type WeightInfo = pallet_child_bounties::weights::SubstrateWeight<Runtime>;
}
```

### Extrinsics

1. [`add_child_bounty(origin, parent_bounty_id, value, description)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L241)
    * Add a child bounty for a parent bounty to divide the work in smaller tasks.
        * `origin` must be the curator of the parent bounty.
        * parent bounty must be `Active`.
        * parent bounty must have enough balance.
        * `value` then is transferred from parent to child bounty account.

2. [`propose_curator(origin, parent_bounty_id, child_bounty_id, curator, fee)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L315)
    * Assign an account to a child bounty as candidate curator.
        * `origin` must be the curator of the parent bounty.
        * parent bounty must be `Active`.
        * child bounty must be in `Added` status.
    * Set status to `CuratorProposed` with `curator`.

3. [`accept_curator(origin, parent_bounty_id, child_bounty_id)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L384)
    * Accept a child bounty assignment from the parent bounty curator, setting a curator deposit.
        * `origin` must be the assigned curator of the parent bounty.
        * A deposit will be reserved from the curator and refund upon successful payout.
    * Set status to `Active`.

4. [`unassign_curator(origin, parent_bounty_id, child_bounty_id)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L460)
    * Unassign an accepted curator from a specific child bounty.
        * `origin` can be:
            * the curator, signaling that they don't want to curate anymore (no slash).
            * `T::RejectOrigin` (from `pallet_treasury`), in that case we slash the curator, considering them malicious or inactive.
            * anybody else, slash if the curator is inactive.
    * Set status to `Added` (so another curator can be assigned to it).

5. [`award_child_bounty(origin, parent_bounty_id, child_bounty_id, beneficiary)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L574)
    * Close and payout the specified amount for the completed work.
        * `origin` must be the parent or the child's curator.
    * Set status to `PendingPayout` with `beneficiary` and `unlock_at` (delay).

6. [`claim_child_bounty(origin, parent_bounty_id, child_bounty_id)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L640)
    * Claim the payout from an awarded child bounty after payout delay.
        * `origin` can be any signed origin.
        * child bounty must be in `PendingPayout` status.
    * Set `ChildBounties[bounty_id] = None`.
    * Remove the bounty's description from `ChildBountyDescriptions`.

7. [`close_child_bounty(origin, parent_bounty_id, child_bounty_id)`](https://github.com/paritytech/substrate/blob/master/frame/child-bounties/src/lib.rs#L750)
    * Cancel a proposed or active child-bounty.
    * Funds are transferred from child to parent bounty account.
    * Curator deposit may be unreserved if possible.
        * `origin` can be:
            * the parent curator, signaling that they don't want to curate anymore (no slash).
            * `T::RejectOrigin` (from `pallet_treasury`), in that case we slash the curator, considering them malicious or inactive.
    * Set `ChildBounties[bounty_id] = None`.
    * Remove the bounty's description from `ChildBountyDescriptions`.

---
