@nexefy/insights-client
v1.1.0
Published
Nexefy Insights API client with type-safe endpoints
Readme
@nexefy/insights-client
Type-safe client for the Nexefy Insights API.
Installation
npm install @nexefy/insights-client @nexefy/auth-clientUsage
import { createNexefyClient } from '@nexefy/auth-client'
import { createInsightsClient } from '@nexefy/insights-client'
// Create auth client
const authClient = createNexefyClient({
authUrl: 'https://auth.nexefy.com',
clientId: 'your-client-id',
organisationSlug: 'your-org'
})
// Create insights client
const insights = createInsightsClient({
apiUrl: 'https://api.nexefy.com/insights',
authClient,
organisationSlug: 'your-org'
})
// Use type-safe methods
const teams = await insights.getUserTeams()
const progress = await insights.getTeamProgress('app-slug')License
MIT
