# @spknetwork/idx-data-utils

> A convenience library for common interactions with user data on ceramic using the IDX protocol over glaze.

Latest version **0.1.0** (published 2022-01-28) · ISC license · 0 weekly downloads

## Install

```sh
npm install @spknetwork/idx-data-utils
pnpm add @spknetwork/idx-data-utils
yarn add @spknetwork/idx-data-utils
bun add @spknetwork/idx-data-utils
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2022-01-28 |
| First published | 2022-01-07 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 95.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | vaultec81, cyphercider |
| Keywords | ceramic, hive |

## Links

- npm: https://www.npmjs.com/package/@spknetwork/idx-data-utils
- Repository: https://github.com/3speaknetwork/spk-auth
- Homepage: https://github.com/3speaknetwork/spk-auth-react#readme
- Issues: https://github.com/3speaknetwork/spk-auth-react/issues
- npm.io page: https://npm.io/package/@spknetwork/idx-data-utils

## Dependencies (2)

- [@ceramicnetwork/common](https://npm.io/package/@ceramicnetwork/common.md) ^1.10.1
- [@datamodels/identity-profile-basic](https://npm.io/package/@datamodels/identity-profile-basic.md) ^0.1.2

## Alternatives

- [lodash.startswith](https://npm.io/package/lodash.startswith.md) — 769.7K weekly downloads
- [@tarojs/service](https://npm.io/package/@tarojs/service.md) — 33.9K weekly downloads
- [io.extendreality.tilia.indicators.spatialtargets.unity](https://npm.io/package/io.extendreality.tilia.indicators.spatialtargets.unity.md) — 131 weekly downloads
- [@rtarojs/taro](https://npm.io/package/@rtarojs/taro.md) — 90 weekly downloads
- [node-branch-io](https://npm.io/package/node-branch-io.md) — 50 weekly downloads

## Recent versions

- 0.1.0 (latest) — 2022-01-28
- 0.0.3 — 2022-01-07
- 0.0.2 — 2022-01-07
- 0.0.1 — 2022-01-07

## README

# @spknetwork/idx-data-utils

A convenience library for common interactions with user data on ceramic using the IDX protocol over [glaze](https://developers.ceramic.network/tools/glaze/overview/).

# Usage

```ts
import { IdxDataService } from '@spknetwork/idx-data-utils'

const service = new IdxDataService(ceramic) // Pass your ceramic client instance

await service.init() // Required to initialize datamodels

// Get profile for the current logged in user
const profile = await service.getOwnProfile()

// Set profile for the current logged in user
await service.writeOwnProfile(profile)

// Get profile for any user by their DID
const profile = await service.getUserProfile(did)
```

## Helper functions

```ts
IdxDataService.isInitialized: () => boolean // will return true if the service instance has been initialized
```

## Note on changes to the IDX protocol and tools

See this recent blog post from ceramic on `datamodels` and `glaze`.

https://blog.ceramic.network/the-next-architecture-for-building-web3-data-applications/

---
_Source: https://npm.io/package/@spknetwork/idx-data-utils · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
