Skip to main content

Hints API

All URIs are relative to http://localhost:1000

MethodHTTP requestDescription
hintsCreateNewHintPOST /hints/create/hints/create [POST]
hintsDeleteSpecificHintPOST /hints/{hint}/delete/hints/{hint}/delete [POST]
hintsSnapshotGET /hints/hints [GET]

hintsCreateNewHint​

Hint hintsCreateNewHint()

This will create a hint.

Example​

import * as Pieces from '@pieces.app/pieces-os-client'

const configuration = Pieces.Configuration()
const apiInstance = new Pieces.HintsApi(configuration)

const body: Pieces.HintsCreateNewHintRequest = {
// SeededHint (optional)
seededHint: ,
};

apiInstance.hintsCreateNewHint(body).then((data: Hint) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))

Parameters​

NameTypeDescriptionNotes
seededHintSeededHint

Return type​

Hint

HTTP request headers​

  • Content-Type: application/json
  • Accept: application/json, text/plain

HTTP response details​

Status codeDescriptionResponse headers
200OK-
500Internal Server Error-

hintsDeleteSpecificHint​

hintsDeleteSpecificHint()

This will delete a specific hint.

Example​

import * as Pieces from '@pieces.app/pieces-os-client'

const configuration = Pieces.Configuration()
const apiInstance = new Pieces.HintsApi(configuration)

const body: Pieces.HintsDeleteSpecificHintRequest = {
// string | This is a specific hint uuid
hint: hint_example,
};

apiInstance.hintsDeleteSpecificHint(body).then((data: void (empty response body)) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))

Parameters​

NameTypeDescriptionNotes
hint[string]This is a specific hint uuiddefaults to undefined

Return type​

void (empty response body)

HTTP request headers​

  • Content-Type: Not defined
  • Accept: text/plain

HTTP response details​

Status codeDescriptionResponse headers
204No Content-
500Internal Server Error-

hintsSnapshot​

Hints hintsSnapshot()

This will get a snapshot of all of the hints.

Example​

import * as Pieces from '@pieces.app/pieces-os-client'

const configuration = Pieces.Configuration()
const apiInstance = new Pieces.HintsApi(configuration)

apiInstance.hintsSnapshot().then((data: Hints) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))

Parameters​

This endpoint does not need any parameters.

Return type​

Hints

HTTP request headers​

  • Content-Type: Not defined
  • Accept: application/json, text/plain

HTTP response details​

Status codeDescriptionResponse headers
200OK-
500Internal Server Error-