Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/...?q=api&page=10&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=api

Returns an array of strings in format "username" or "username/projectName"

Found 18960 results for "api"(2957ms)

Glancer_README.md2 matches

@lightweight•Updated 21 hours ago
8// Initialize Notion client
9const notion = new Client({
10 auth: Deno.env.get("NOTION_API_KEY"),
11});
12```
13
14Keeping controllers in this directory and importing them into our routes keeps our API endpoints thin and easier to work with. (See the /tasks directory as an example.)
15
16## Re: /controllers and /utils

Glancer_README.md1 match

@lightweight•Updated 21 hours ago
7### Task endpoints use /controllers to get and save data
8
9In order to keep the API easy to look and work with, the routes in /tasks handle routing but do not get data from or save data to Notion. The functions that connect to Notion live in the /controllers directory, and are _called_ from the endpoints in /tasks.
10
11### Naming convention for routes and controllers

Glancercobrowse.tasks.routes.ts1 match

@lightweight•Updated 21 hours ago
13 console.log(page.id);
14 // get the cobrowse value from the payload
15 // warning: properties in Notion are capitalized as a convention (see Cobrowse)
16 const cobrowse = page.properties.Cobrowse.checkbox ? false : true;
17 // save new cobrowse boolean to Notion page

Glancerpage.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { Hono } from "npm:hono";
2import { getPage } from "../../controllers/page.controller.ts";
3
4const app = new Hono();
5

Glancerdemo.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { Hono } from "npm:hono";
2import { getPage } from "../../controllers/page.controller.ts";
3
4const app = new Hono();
5

Glancerdatabase.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { Hono } from "npm:hono";
2import { getDatabase } from "../../controllers/database.controller.ts";
3
4const app = new Hono();
5

Glancercobrowse.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { blob } from "https://esm.town/v/std/blob?v=12";
2import { Hono } from "npm:hono";
3import { blobKeyForDemoCobrowseStatus } from "../../../shared/utils/blobKeyForDemoCobrowseStatus.ts";
4
5const app = new Hono();

Glanceractions.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { Hono } from "npm:hono";
2import {
3 getDemoInteractions,
4 getAllInteractionsPages,
5} from "../../controllers/actions.controller.ts";

Glanceraction.api.routes.ts0 matches

@lightweight•Updated 21 hours ago
1import { Hono } from "npm:hono";
2import { setAction } from "../../controllers/action.controller.ts";
3
4const app = new Hono();
5

Sketch_IdeasStylesViewer.tsx1 match

@tvhees•Updated 22 hours ago
9
10 useEffect(() => {
11 fetch("/api/styles")
12 .then(res => res.json())
13 .then(data => {

beeminder-api4 file matches

@cricks_unmixed4u•Updated 16 hours ago

shippingAPI1 file match

@dynamic_silver•Updated 1 day ago
apiry
snartapi