# W3bstream Tasks

{% hint style="info" %}
This documentation is currently being updated. Please check back later for the latest version.
{% endhint %}

```go
type Task struct {
	// This is the task unique identifier, represented as a Hash
	ID             common.Hash `json:"id"`
	// This is the sequence number for the task to ensure ordering and prevent replay
	Nonce          uint64      `json:"nonce"`
	// This is the DePIN Project ID, represented as a big integer
	ProjectID      *big.Int    `json:"projectID"`
	// This represent a specific version for the project file in case it's been updated
	ProjectVersion string      `json:"projectVersion,omitempty"`
	// This is the public key of the device (or "client") that authorized the task
	DevicePubKey   []byte      `json:"devicePublicKey"`
	// This is the raw data payload containing the message(s) to be processed
	Payload        []byte      `json:"payload"`
	// This is the cryptographic signature of the task
	Signature      []byte      `json:"signature,omitempty"`
	// This is the hash of the payload data
	PayloadHash    common.Hash `json:"payloadHash,omitempty"`
	// This is the hash of the task structure itself
	TaskHash       common.Hash `json:"taskHash,omitempty"`
	// This points to the previous task in the sequence, forming a chain
	PrevTask       *Task       `json:"previousTask,omitempty"`
}
```

<https://github.com/iotexproject/w3bstream/blob/283aae188f03f9dfd0ef40027fd9ab837e41a9c9/task/task.go#L14>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.iotex.io/depin/iotex-depin-modules/w3bstream/build-with-w3bstream/get-started/w3bstream-tasks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
