Skip to main content
Glama
types.d.ts1.41 kB
// Type declarations for Strudel packages (which don't ship types) declare module "@strudel/core" { export class Pattern { constructor(query: (state: any) => any[], steps?: number); queryArc(begin: number, end: number): Hap[]; firstCycle(): Hap[]; withValue(func: (value: any) => any): Pattern; fast(factor: number): Pattern; slow(factor: number): Pattern; rev(): Pattern; } export class Hap { whole: TimeSpan | null; part: TimeSpan; value: any; context: any; hasOnset(): boolean; withValue(func: (value: any) => any): Hap; } export class TimeSpan { begin: Fraction; end: Fraction; } export class Fraction { valueOf(): number; toString(): string; } export function sequence(...patterns: any[]): Pattern; export function stack(...patterns: any[]): Pattern; export function cat(...patterns: any[]): Pattern; } declare module "@strudel/mini" { import { Pattern } from "@strudel/core"; export function mini(...strings: string[]): Pattern; export function mini2ast(code: string, start?: number, userCode?: string): any; export function getLeafLocations(code: string): Array<{ value: string; start: number; end: number; }>; } declare module "@strudel/tonal" { export function scale(name: string): any; export function chord(name: string): any; export function voicing(options?: any): any; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/takeachangs/strudel-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server