Problem methods: notify, rank, suggest, vote
The Problem Verbs notify, rank, suggest, vote as typed SDK methods, with inputs, result, refusals and an example.
Reference for Problem, one group of Problem methods.
Problem.notify
Notify tells every Contact who voted on a Problem that a Version addressing it shipped, with a link to the change. Verb page.
interface ProblemVerbs {
notify(input: ProblemNotifyInput, options?: SB.CallOptions): SB.Call<Problem>
}Emits Problem.notified.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
problem | Problem | required | The Problem the Version addresses. |
version | Version | The Version that shipped. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
problem | Problem | required | The Problem, marked addressed. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
import { $ } from 'startup-builder'
const problem = await $.Problem.notify({ problem: 'problem_UzvXXfKsJB' })Problem.rank
Rank orders Problems by revenue at stake, Evidence grade and effort, so the next Project addresses the top one. Verb page.
interface ProblemVerbs {
rank(input?: ProblemRankInput, options?: SB.CallOptions): SB.Call<Problem[]>
}Emits Problem.ranked.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
icp | ICP | The ICP whose Problems to rank; omitted, every ICP. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
problems | list of Problem | required | Problems, highest first, each with its score. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
import { $ } from 'startup-builder'
const problems = await $.Problem.rank({ icp: 'icp_EwhsJU4AOW' })Problem.suggest
Suggest records a Customer’s ask for something the Product lacks as Evidence on a Problem, with the asker attached. Verb page.
interface ProblemVerbs {
suggest(input: ProblemSuggestInput, options?: SB.CallOptions): SB.Call<ProblemSuggestOutput>
}Emits Problem.suggested.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
text | text | required | The ask, in the asker’s words. |
problem | Problem | The Problem it bears on; an Agent maps it when the asker names none. | |
via | string | Where it was asked: an App, the Portal, or an Agent’s answer. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
evidence | Evidence | required | The Evidence, Opinion grade, with askedBy set. |
problem | Problem | required | The Problem with the new Evidence attached. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
import { $ } from 'startup-builder'
const { evidence, problem } = await $.Problem.suggest({ text: 'Example text' })Problem.vote
Vote records a Contact saying a Problem on the public board is theirs too, with their words kept as Evidence. Verb page.
interface ProblemVerbs {
vote(input: ProblemVoteInput, options?: SB.CallOptions): SB.Call<Problem>
}Emits Problem.voted.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
problem | Problem | required | The Problem. |
contact | Contact | required | Who votes. |
words | text | What they said, in their own words. |
Returns
| Output | Type | Required | Description |
|---|---|---|---|
problem | Problem | required | The Problem, with the vote counted. |
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | None. |
Example
import { $ } from 'startup-builder'
const problem = await $.Problem.vote({ problem: 'problem_UzvXXfKsJB', contact: 'contact_WsrosCQi6J' })