List
List
client.me.vals.list(ValListParamsquery, RequestOptionsoptions?): PageCursorURL<idstringauthorAuthorcreatedAtstringdescriptionunionimageUrlunionlinksLinksnamestringprivacyunionVal>
get/v2/me/vals
[BETA] List all of a user's vals for authenticated users
Parameters
querylimitnumberoffsetnumberValListParams
Returns
import ValTown from '@valtown/sdk';
const client = new ValTown({
bearerToken: 'My Bearer Token',
});
// Automatically fetches more pages as needed.
for await (const val of client.me.vals.list({ limit: 1, offset: 0 })) {
console.log(val.id);
}
200 Example
{
"data": [
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"author": {
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"username": "username"
},
"createdAt": "2019-12-27T18:11:19.117Z",
"description": "description",
"imageUrl": "imageUrl",
"links": {
"html": "https://example.com",
"self": "https://example.com"
},
"name": "name",
"privacy": "public"
}
],
"links": {
"self": "https://example.com",
"next": "https://example.com",
"prev": "https://example.com"
}
}