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/image-url.jpg%20%22Optional%20title%22?q=api&page=191&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 15692 results for "api"(3031ms)

templateTwitterAlert1README.md4 matches

@charmaine•Updated 1 week ago
31Refer to [Twitter's search operators](https://socialdata.gitbook.io/docs/twitter-tweets/retrieve-search-results-by-keyword#endpoint-parameters) to fine-tune your query.
32
33### 4. Test API call
34Set `isProd = false` in the code if you are testing, to ensure there are enough tweets to display. <br>
35Toggle it back to `true` when you're ready to run this cron job in production and actuall send notifications.
60
61### NOTE: Usage Limits
62This val uses the SocialData API for Twitter data:
63
64- **Proxies via Val Town's [SocialDataProxy](https://www.val.town/v/stevekrouse/socialDataProxy)**: Limited to 10 cents per day for [**Val Town Pro users**](https://www.val.town/pricing). This API is *only* for Pro users.
65- **Need more calls?** Sign up for your own [SocialData API token](https://socialdata.tools) and configure the [`socialDataSearch`](https://www.val.town/v/stevekrouse/socialDataSearch) function.

autonomous-valdiagram.tsx1 match

@abrinz•Updated 1 week ago
5 linkStyle default stroke:#aaaaaa,stroke-width:1.5px
6
7 API[API] <--> Agent
8
9 subgraph "Agent Runtime"

autonomous-valagent.tsx2 matches

@abrinz•Updated 1 week ago
17
18export default async function POST(req: Request) {
19 if (req.headers.get("Authorization") !== `Bearer ${Deno.env.get("AGENT_API_KEY")}`) {
20 return new Response("Unauthorized", { status: 401 });
21 }
34 const maxSteps = 10;
35
36 const model = Deno.env.get("ANTHROPIC_API_KEY") ? anthropic("claude-3-7-sonnet-latest") : openai("gpt-4.1");
37
38 const options = {

autonomous-valtools.tsx4 matches

@abrinz•Updated 1 week ago
77 }),
78 execute: async ({ query }) => {
79 const apiKey = Deno.env.get("EXA_API_KEY");
80 const exa = new Exa(apiKey);
81 const result = await exa.searchAndContents(query, {
82 text: true,
100 }),
101 execute: async ({ url }) => {
102 const apiKey = Deno.env.get("EXA_API_KEY");
103 const exa = new Exa(apiKey);
104 const result = await exa.getContents([url], { text: true });
105 return {

untitled-7748telegram-image-bot.ts3 matches

@Rajparbat01•Updated 1 week ago
5const openai = new OpenAI();
6
7// Telegram Bot API types
8interface TelegramUpdate {
9 update_id: number;
43 }
44
45 const response = await fetch(`https://api.telegram.org/bot${botToken}/sendMessage`, {
46 method: "POST",
47 headers: {
70 }
71
72 const response = await fetch(`https://api.telegram.org/bot${botToken}/sendPhoto`, {
73 method: "POST",
74 headers: {

untitled-7748main.tsx1 match

@Rajparbat01•Updated 1 week ago
1I need a fully functional, user-friendly, and editable mobile app for my tiffin service business named "Kusum’s Kitchen," operating in DLF2 Newtown, Kolkata. The app should be developed for both Android and iOS platforms using a framework like Flutter or React Native to ensure cross-platform compatibility. The app should be interactive, professional, and easy to navigate for customers, including features like an editable menu tab, a customer feedback section, and a UPI payment gateway. Below are the detailed requirements:App Overview:App Name: Kusum’s KitchenPurpose: To allow customers to browse the menu, place orders for tiffin meals (veg and non-veg thalis), subscribe to monthly plans, make payments via UPI, provide feedback, and contact the business.Target Audience: Residents of DLF2 Newtown, Kolkata, including IT professionals, families, and students who need daily tiffin services.Key Features and Requirements:Home Screen:Display the business name "Kusum’s Kitchen" with a logo placeholder (a simple placeholder image of a thali can be used if a logo isn’t provided).A welcoming banner with a tagline: "Authentic Bengali Tiffin Service in DLF2 Newtown!"Quick navigation buttons for: Menu, Subscription Plans, Order Now, Feedback, and Contact Us.A rotating banner showcasing USPs: "Authentic Bengali Dishes," "Eco-Friendly Packaging," "Free Dessert with Every Order," and "No Repeat Menu."Menu Tab (Editable):An editable menu section where I can add, update, or remove dishes in the future.Categories: Breakfast, Lunch, Dinner.Subcategories: Veg Thali (₹120), Non-Veg Thali (₹150).Example dishes to include initially:Veg Thali: Rice, Dal, Aloo Posto, Mixed Veg Sabji, Roti, Free Dessert/Papad.Non-Veg Thali: Rice, Dal, Shorshe Ilish, Veg Sabji, Roti, Free Dessert/Papad.Each dish should have a name, price, description, and an image placeholder (use generic thali images if specific images aren’t provided).Admin access (via a simple login: username "admin," password "kusum123") to edit the menu (add/remove dishes, update prices, descriptions, etc.).Customers can view the daily menu with a "Today’s Special" section (e.g., "Aloo Posto Thali" on Monday).Order Placement:Interactive ordering system where customers can select a thali (Veg/Non-Veg), choose a time slot (e.g., Lunch: 12:30 PM, Dinner: 7:30 PM), and specify quantity.Option to customize orders (e.g., "Low-Oil," "No Onion/Garlic").Cart functionality to review selected items before checkout.Order summary showing total price, delivery address, and estimated delivery time.Subscription Plans:Section for subscription plans with pricing:Weekly Veg Plan: ₹770 (7 meals, ~₹110/meal).Monthly Veg Plan: ₹3,300 (30 meals, ~₹110/meal, includes 2 free meals).Weekly Non-Veg Plan: ₹980 (7 meals, ~₹140/meal).Monthly Non-Veg Plan: ₹4,200 (30 meals, ~₹140/meal, includes 2 free meals).Option to subscribe directly from the app with a confirmation message (e.g., “You’ve subscribed to the Monthly Veg Plan!”).Display benefits: "No Delivery Fees," "2 Free Meals with Monthly Plan."Payment Gateway (UPI):Integrate a UPI payment gateway (e.g., Razorpay or Paytm API) for seamless payments.Support popular UPI apps like Google Pay, PhonePe, and Paytm.After selecting items or a subscription plan, customers should be redirected to a payment page to enter their UPI ID or scan a QR code.Payment confirmation with a success message (e.g., “Payment Successful! Your order will be delivered by 12:30 PM.”).Customer Feedback Section:A dedicated feedback tab where customers can rate their experience (1–5 stars) and leave comments.Fields: Order ID (auto-filled if possible), Rating, Comments.Display recent feedback on the app (e.g., “5 Stars: Loved the Shorshe Ilish!”) with an option for me to respond as admin (e.g., “Thank you for your feedback!”).Feedback data should be stored in a simple database (e.g., SQLite or Firebase) for future reference.Contact Information:A Contact Us section with the following details:Contact Number: 7278221303Email ID: rajparbat92@gmail.comAddress: Plot-1, Sunrise Tower, DLF 2 Road, Kolkata 700156Interactive options: Click-to-call button for the contact number, click-to-email button for the email ID, and a Google Maps link for the address.Social media link: Instagram handle @kusumskitchen_kolkata (clickable to open Instagram).User-Friendly Features:User login/registration (via phone number or email) to save order history and subscription details.Order tracking: Simple status updates (e.g., “Order Confirmed,” “Preparing,” “Out for Delivery”).Push notifications for daily menu updates, order confirmations, and delivery updates (e.g., “Today’s Special: Aloo Posto Thali!”).Dark/light theme toggle for better accessibility.Multilingual support: English and Bengali (e.g., menu and labels in both languages).Admin Features (Editable/Modifiable):Admin dashboard (accessible via admin login) to:Edit the menu (add/remove dishes, update prices).View and respond to customer feedback.View order history and subscription details.Update contact information if needed.Use a simple backend (e.g., Firebase or Node.js with MongoDB) to store and manage data (menu, orders, feedback).Design and Usability:Vibrant color scheme: Orange, green, and white (to reflect the vibrancy of Bengali cuisine).Professional and clean layout with high-quality placeholder images of thalis (e.g., rice, dal, sabji, roti, Shorshe Ilish).Intuitive navigation with a bottom navigation bar (Home, Menu, Orders, Feedback, Contact).Interactive buttons (e.g., “Add to Cart,” “Subscribe Now”) with hover/click effects.Responsive design for various screen sizes (phones and tablets).Additional Features:Loyalty Program: Display “Earn 1 Free Meal After 10 Orders!” with a progress tracker (e.g., “You’ve ordered 5 meals – 5 more to go!”).Daily Notifications: Send daily menu updates via push notifications (e.g., “Today’s Menu: Veg Thali with Aloo Posto!”).Order History: A tab for users to view past orders and reorder with one click.

my-first-valAlgorithmSelector.tsx1 match

@moizedits•Updated 1 week ago
35 {categories.map(category => (
36 <div key={category} className="mb-4">
37 <h3 className="text-lg font-medium capitalize mb-2">{category} Algorithms</h3>
38 <div className="space-y-2">
39 {algorithmsByType[category].map(algorithm => (

my-first-valApp.tsx2 matches

@moizedits•Updated 1 week ago
28 useEffect(() => {
29 if (!initialData.algorithms) {
30 fetch('/api/algorithms')
31 .then(res => res.json())
32 .then(data => setAlgorithms(data.algorithms))
42 setCurrentStepIndex(0);
43
44 let url = `/api/algorithms/${selectedAlgorithm.id}/steps?array=${JSON.stringify(array)}`;
45 if (target !== undefined && selectedAlgorithm.type === 'searching') {
46 url += `&target=${target}`;

my-first-valindex.html1 match

@moizedits•Updated 1 week ago
7 <script src="https://cdn.twind.style" crossorigin></script>
8 <script src="https://esm.town/v/std/catch"></script>
9 <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap">
10 <style>
11 body {

my-first-valindex.ts3 matches

@moizedits•Updated 1 week ago
10});
11
12// API routes
13app.get('/api/algorithms', (c) => {
14 return c.json({
15 algorithms
17});
18
19app.get('/api/algorithms/:id/steps', async (c) => {
20 const id = c.req.param('id');
21 const url = new URL(c.req.url);

googleGeminiAPI2 file matches

@michaelwschultz•Updated 7 hours ago

HN-fetch-call2 file matches

@ImGqb•Updated 3 days ago
fetch HackerNews by API
Kapil01
apiv1