Skip to content
Developers

Collections

Collections in Tallyfy Answers group similar objects together.

Each collection works like a table in a relational database, letting objects be compared, filtered, searched, and ranked.

How do collections work in Tallyfy Answers?

Section titled “How do collections work in Tallyfy Answers?”

A Tallyfy Answers collection is:

  • A logical container for related objects
  • Like a table in a traditional database
  • Built for organizing data with similar structures
  • Flexible enough to adapt as your data changes

Tallyfy Answers collections give you several key features:

  • Automatic property types1: Each property’s type is set the first time an object carrying it is indexed
  • Efficient organization: Group related objects to make management easier
  • Searchability: Search across all objects within a collection
  • Schema: Get the collection’s detected schema

What operations can you perform on collections?

Section titled “What operations can you perform on collections?”

Here’s what you can do with Tallyfy Answers collections:

  • Create a collection - Set up a new data container
  • Get a collection - Get the collection’s detected schema
  • Delete a collection - Remove a collection and its objects
  • List every object in a collection with GET /collections/{collection_name}/objects. It needs the API key and returns every object in one response, with no paging.
  • Delete every object but keep the collection with DELETE /collections/{collection_name}/objects. It needs the API key.
  • Count objects per source with GET /collections/{collection_name}/objects/metadata. It needs no key and returns a list such as [{"product": "Docs", "count": 42}], or [] for a collection that’s empty or doesn’t exist.

There’s no endpoint that lists your collections or changes a collection after it’s created.

What are the best practices for using collections?

Section titled “What are the best practices for using collections?”

Think about these guidelines when working with Tallyfy Answers collections:

  • Use clear, descriptive names for your collections, made of lowercase letters and digits
  • Group similar objects with consistent structures
  • Create separate collections for very different data types
  • Plan your collection structure before bringing in large datasets
  • Use collection names that show what objects they contain

Browse all Tallyfy Answers collection management operations below:

Answers > Objects

Objects are the JSON records you store in a Tallyfy Answers collection. They’re indexed in…
  1. Answers stores objects in Weaviate, which detects each new property’s type the first time it sees it ↩