---
title: "Accept block"
method: POST
path: "/bus/consensus/acceptblock"
tags: ["bus"]
---

# Accept block

`POST /bus/consensus/acceptblock`

Adds the block to the chain manager and broadcasts the block header.

## Request body

- Block
  - `parentID` string — The ID of the parent block
  - `nonce` integer — The nonce used to mine the block
  - `timestamp` string, date-time — The time the block was mined
  - `minerPayouts` SiacoinOutput[]
    - `value` string — The amount of Siacoins in the output
    - `address` string — The hash of a set of UnlockConditions
  - `transactions` Transaction[]
    - `siacoinInputs` SiacoinInput[] — List of Siacoin inputs used in the transaction.
      - `parentID` string — The ID of the output being spent
      - `unlockConditions` object — The unlock conditions required to spend the output
        - `timelock` integer — The block height at which the outputs can be spent
        - `publicKeys` UnlockKey[]
          - `algorithm` string, bytes — A fixed 16-byte array that specifies the algorithm used to generate the key
          - `key` string, bytes — A 32-byte key represented as a hex-encoded string. Must be exactly 64 characters long, containing only hexadecimal digits
        - `signaturesRequired` integer — The number of signatures required to spend the output
    - `siacoinOutputs` SiacoinOutput[] — List of Siacoin outputs created by the transaction.
      - `value` string — The amount of Siacoins in the output
      - `address` string — The hash of a set of UnlockConditions
    - `fileContracts` FileContract[] — List of file contracts created by the transaction.
      - `filesize` integer — The size of the contract in bytes.
      - `fileMerkleRoot` string — The Merkle root of the contract's data.
      - `windowStart` integer — The block height when the contract's proof window starts.
      - `windowEnd` integer — The block height when the contract's proof window ends.
      - `payout` string — The total payout for the contract.
      - `validProofOutputs` SiacoinOutput[] — List of outputs created if the contract is successfully fulfilled.
        - `value` string — The amount of Siacoins in the output
        - `address` string — The hash of a set of UnlockConditions
      - `missedProofOutputs` SiacoinOutput[] — List of outputs created if the contract is not fulfilled.
        - `value` string — The amount of Siacoins in the output
        - `address` string — The hash of a set of UnlockConditions
      - `unlockHash` string — The hash of a set of UnlockConditions
      - `revisionNumber` integer — The revision number of the contract
    - `fileContractRevisions` FileContractRevision[] — List of revisions to existing file contracts included in the transaction.
      - `parentID` string — The ID of the parent file contract being revised.
      - `unlockConditions` object — The conditions required to unlock the contract for revision.
        - `timelock` integer — The block height at which the outputs can be spent
        - `publicKeys` UnlockKey[]
          - `algorithm` string, bytes — A fixed 16-byte array that specifies the algorithm used to generate the key
          - `key` string, bytes — A 32-byte key represented as a hex-encoded string. Must be exactly 64 characters long, containing only hexadecimal digits
        - `signaturesRequired` integer — The number of signatures required to spend the output
      - `filesize` integer — The size of the file in bytes after the revision.
      - `fileMerkleRoot` string — The updated Merkle root of the file's data.
      - `windowStart` integer — The block height when the revised proof window starts.
      - `windowEnd` integer — The block height when the revised proof window ends.
      - `validProofOutputs` SiacoinOutput[] — Updated outputs if the revised contract is successfully fulfilled.
        - `value` string — The amount of Siacoins in the output
        - `address` string — The hash of a set of UnlockConditions
      - `missedProofOutputs` SiacoinOutput[] — Updated outputs if the revised contract is not fulfilled.
        - `value` string — The amount of Siacoins in the output
        - `address` string — The hash of a set of UnlockConditions
      - `unlockHash` string — The updated hash of the conditions required to unlock the contract funds.
      - `revisionNumber` integer — The revision number of the contract
    - `storageProofs` StorageProof[] — List of storage proofs asserting the storage of data for file contracts.
      - `parentID` string — The ID of the file contract being proven.
      - `leaf` string, byte — The selected leaf from the Merkle tree of the file's data.
      - `proof` Hash256[] — The Merkle proof demonstrating the inclusion of the leaf.
    - `siafundInputs` SiafundInput[] — List of Siafund inputs spent in the transaction.
      - `parentID` string — The ID of the parent Siafund output being spent.
      - `unlockConditions` object — The conditions required to unlock the parent Siafund output.
        - `timelock` integer — The block height at which the outputs can be spent
        - `publicKeys` UnlockKey[]
          - `algorithm` string, bytes — A fixed 16-byte array that specifies the algorithm used to generate the key
          - `key` string, bytes — A 32-byte key represented as a hex-encoded string. Must be exactly 64 characters long, containing only hexadecimal digits
        - `signaturesRequired` integer — The number of signatures required to spend the output
      - `claimAddress` string — The address receiving the Siacoin claim generated by the Siafund output.
    - `siafundOutputs` SiafundOutput[] — List of Siafund outputs created by the transaction.
      - `value` integer — The amount of Siafund in the output.
      - `address` string — The address receiving the Siafund.
    - `minerFees` Currency[] — List of miner fees included in the transaction.
    - `arbitraryData` string[] — Arbitrary binary data included in the transaction.
    - `signatures` TransactionSignature[] — List of cryptographic signatures verifying the transaction.
      - `parentID` string — The ID of the transaction being signed
      - `publicKeyIndex` integer — The index of the public key used to sign the transaction
      - `timelock` integer — The block height at which the outputs in the transaction can be spent
      - `coveredFields` object — Indicates which fields of the transaction are covered by the signature
        - `wholeTransaction` boolean — Whether the whole transaction is covered by the signature
        - `siacoinInputs` integer[]
        - `siacoinOutputs` integer[]
        - `fileContracts` integer[]
        - `fileContractRevisions` integer[]
        - `storageProofs` integer[]
        - `siafundInputs` integer[]
        - `siafundOutputs` integer[]
        - `minerFees` integer[]
        - `arbitraryData` integer[]
        - `signatures` integer[]
      - `signature` string, byte — The signature of the transaction
  - `v2` V2BlockData
    - `height` integer — The height of the block
    - `commitment` string — A 256-bit blake2b hash
    - `transactions` V2Transaction[]
      - `siacoinInputs` V2SiacoinInput[]
        - `parent` SiacoinElement
          - `id` string — The ID of the element
          - `stateElement` object — The state of the element
            - `leafIndex` integer — The index of the element in the Merkle tree
            - `merkleProof` Hash256[] — The Merkle proof demonstrating the inclusion of the leaf
          - `siafundOutput` object — The output of the element
            - `value` string — The amount of Siacoins in the output
            - `address` string — The hash of a set of UnlockConditions
          - `maturityHeight` integer — The block height when the output matures
        - `satisfiedPolicy` SatisfiedPolicy
          - `policy` object
          - `signature` Signature[]
          - `preimages` string[]
      - `siacoinOutputs` SiacoinOutput[]
        - `value` string — The amount of Siacoins in the output
        - `address` string — The hash of a set of UnlockConditions
      - `siafundInputs` V2SiafundInput[]
        - `parent` SiafundElement
          - `id` string — The ID of the element
          - `stateElement` object — The state of the element
            - `leafIndex` integer — The index of the element in the Merkle tree
            - `merkleProof` Hash256[] — The Merkle proof demonstrating the inclusion of the leaf
          - `siafundOutput` object — The output of the element
            - `value` integer — The amount of Siafund in the output.
            - `address` string — The address receiving the Siafund.
          - `claimStart` string — value of SiafundTaxRevenue when element was created
        - `claimAddress` string — The hash of a set of UnlockConditions
        - `satisfiedPolicy` SatisfiedPolicy
          - `policy` object
          - `signature` Signature[]
          - `preimages` string[]
      - `siafundOutputs` SiafundOutput[]
        - `value` integer — The amount of Siafund in the output.
        - `address` string — The address receiving the Siafund.
      - `fileContracts` V2FileContract[]
        - `capacity` integer
        - `filesize` integer
        - `fileMerkleRoot` string — A 256-bit blake2b hash
        - `proofHeight` integer
        - `expirationHeight` integer
        - `renterOutput` SiacoinOutput
          - `value` string — The amount of Siacoins in the output
          - `address` string — The hash of a set of UnlockConditions
        - `hostOutput` SiacoinOutput
          - `value` string — The amount of Siacoins in the output
          - `address` string — The hash of a set of UnlockConditions
        - `missedHostValue` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
        - `totalCollateral` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
        - `renterPublicKey` string — A ed25519 public key
        - `hostPublicKey` string — A ed25519 public key
        - `revisionNumber` integer — The revision number of the contract
        - `renterSignature` string, byte — A ed25519 signature
        - `hostSignature` string, byte — A ed25519 signature
      - `fileContractRevisions` V2FileContractRevision[]
        - `parent` V2FileContractElement
          - `id` string — The ID of the element
          - `stateElement` object — The state of the element
            - `leafIndex` integer — The index of the element in the Merkle tree
            - `merkleProof` Hash256[] — The Merkle proof demonstrating the inclusion of the leaf
          - `v2FileContract` V2FileContract
            - `capacity` integer
            - `filesize` integer
            - `fileMerkleRoot` string — A 256-bit blake2b hash
            - `proofHeight` integer
            - `expirationHeight` integer
            - `renterOutput` SiacoinOutput
              - …
            - `hostOutput` SiacoinOutput
              - …
            - `missedHostValue` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
            - `totalCollateral` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
            - `renterPublicKey` string — A ed25519 public key
            - `hostPublicKey` string — A ed25519 public key
            - `revisionNumber` integer — The revision number of the contract
            - `renterSignature` string, byte — A ed25519 signature
            - `hostSignature` string, byte — A ed25519 signature
        - `revision` V2FileContract
          - `capacity` integer
          - `filesize` integer
          - `fileMerkleRoot` string — A 256-bit blake2b hash
          - `proofHeight` integer
          - `expirationHeight` integer
          - `renterOutput` SiacoinOutput
            - `value` string — The amount of Siacoins in the output
            - `address` string — The hash of a set of UnlockConditions
          - `hostOutput` SiacoinOutput
            - `value` string — The amount of Siacoins in the output
            - `address` string — The hash of a set of UnlockConditions
          - `missedHostValue` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
          - `totalCollateral` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
          - `renterPublicKey` string — A ed25519 public key
          - `hostPublicKey` string — A ed25519 public key
          - `revisionNumber` integer — The revision number of the contract
          - `renterSignature` string, byte — A ed25519 signature
          - `hostSignature` string, byte — A ed25519 signature
      - `fileContractResolutions` V2FileContractResolution[]
        - `parent` V2FileContractElement
          - `id` string — The ID of the element
          - `stateElement` object — The state of the element
            - `leafIndex` integer — The index of the element in the Merkle tree
            - `merkleProof` Hash256[] — The Merkle proof demonstrating the inclusion of the leaf
          - `v2FileContract` V2FileContract
            - `capacity` integer
            - `filesize` integer
            - `fileMerkleRoot` string — A 256-bit blake2b hash
            - `proofHeight` integer
            - `expirationHeight` integer
            - `renterOutput` SiacoinOutput
              - …
            - `hostOutput` SiacoinOutput
              - …
            - `missedHostValue` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
            - `totalCollateral` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).
            - `renterPublicKey` string — A ed25519 public key
            - `hostPublicKey` string — A ed25519 public key
            - `revisionNumber` integer — The revision number of the contract
            - `renterSignature` string, byte — A ed25519 signature
            - `hostSignature` string, byte — A ed25519 signature
        - `resolution` object
      - `attestations` Attestation[]
        - `publicKey` string — A ed25519 public key
        - `key` string
        - `value` string, byte
        - `signature` string, byte — A ed25519 signature
      - `arbitraryData` string[]
      - `newFoundationAddress` string — The hash of a set of UnlockConditions
      - `minerFee` string — An unsigned amount of Hastings, the smallest unit of currency in Sia. 1 Siacoin (SC) equals 10^24 Hastings (H).

## Response `200`

Successfully accepted block

## Other responses

- `500` — Internal server error

---

[API](https://skmtc.net/siafoundation/apis/renterd-api.md) · [All operations](https://skmtc.net/siafoundation/apis/renterd-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/siafoundation/renterd-api/versions/184a3d5207da/schema)
