Skip to content
← Public packages

@kody/integrations-sh

Client for the public integrations.sh registry: search, detect, cached surface, and live discover.

src/index.ts

41 lines · 1.5 KB · TypeScript
import search from './search.ts'
import detect from './detect.ts'
import discover from './discover.ts'
import surface from './surface.ts'

export { default as search } from './search.ts'
export { default as detect } from './detect.ts'
export { default as surface } from './surface.ts'
export { default as discover } from './discover.ts'
export { default as smokeTest } from './smoke-test.ts'
export { normalizeProviderDomain } from './domain.ts'
export type { SearchInput, SearchOutput } from './search.ts'
export type { DetectInput, DetectOutput } from './detect.ts'
export type { SurfaceInput, SurfaceOutput } from './surface.ts'
export type { DiscoverInput, DiscoverOutput } from './discover.ts'
export type { SearchResult, Surface, Credential } from './types.ts'

/**
 * Search the public integrations.sh catalog.
 * Prefer `/search`, `/detect`, `/surface`, or `/discover` when you only need one action.
 * Person accounts must community_fork this package first.
 *
 * @param input - Same as search()
 * @returns Catalog matches
 *
 * @example
 * import integrationsSh from 'kody:@<username>/integrations-sh'
 * const { results } = await integrationsSh({ query: 'github' })
 */
async function integrationsSh(
	input: Parameters<typeof search>[0],
): Promise<Awaited<ReturnType<typeof search>>> {
	return search(input)
}

integrationsSh.search = search
integrationsSh.detect = detect
integrationsSh.surface = surface
integrationsSh.discover = discover

export default integrationsSh