Index

The Index model is a fundamental component of the Index Network, designed to facilitate context management and enable semantic interoperability within your system. It serves as a structured way to organize and store data related to specific contexts. Below is a description of the Index schema and its primary functions:

To create an index, you should first mint a LIT Programmable Key Pair (PKP).

Mint a new PKP on Testnet

Index Schema

The Index schema consists of several key properties:

Property
Type
Description

title

String

The title or name associated with the Index, providing context identification.

signerFunction

CID

IPFS CID that stores the Lit Action function

signerPublicKey

String

Public key of the minted LIT Programmable Key Pair

updatedAt

DateTime

The timestamp when the Index was last updated, ensuring data accuracy.

deletedAt

DateTime

The timestamp when the Index was deleted (if applicable).

controllerDID

DID (Identifier)

The Decentralized Identifier (DID) of the controller for access control.

Endpoints

This section provides details about the available API endpoints.

Create index

post
Authorizations
Body
titlestringOptional
signerPublicKeystringOptional
signerFunctionstringOptional
Responses
201
Index created
post
POST /api/indexes HTTP/1.1
Host: dev.index.network
Authorization: Bearer DID_SESSION_SERIALIZED
Content-Type: application/json
Accept: */*
Content-Length: 65

{
  "title": "text",
  "signerPublicKey": "text",
  "signerFunction": "text"
}
201

Index created

No content

Get index by ID

get
Path parameters
idstringRequired

Index ID

Responses
200
Successful operation
get
GET /api/indexes/{id} HTTP/1.1
Host: dev.index.network
Accept: */*
200

Successful operation

No content

Update index

patch
Authorizations
Path parameters
idstringRequired

Index ID

Body
titlestringOptional
signerFunctionstringOptional
Responses
200
Index updated
patch
PATCH /api/indexes/{id} HTTP/1.1
Host: dev.index.network
Authorization: Bearer DID_SESSION_SERIALIZED
Content-Type: application/json
Accept: */*
Content-Length: 40

{
  "title": "text",
  "signerFunction": "text"
}
200

Index updated

No content

Delete index

delete
Authorizations
Path parameters
idstringRequired

Index ID

Responses
200
Index deleted
delete
DELETE /api/indexes/{id} HTTP/1.1
Host: dev.index.network
Authorization: Bearer DID_SESSION_SERIALIZED
Accept: */*
200

Index deleted

No content

Last updated