Metadata-Version: 2.1
Name: synapseconvert
Version: 0.1.1
Summary: Tools for converting Synapse RTP (research transport protocol) JSON to spreadsheet and back.
Author-email: Samuel Baylis <request@biblicalstory.org>
License: MIT License
        
        Copyright (c) 2025 Samuel Andrew Baylis
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pandas
Requires-Dist: openpyxl


# synapseconvert

A simple two-way converter for Synapse-style libraries (collections → categories → items) using Excel and JSON. This is intended for developers working with [Synapse](https://biblicalstory.org/tools/synapse), a research transport protocol designed for structured academic resources.

## 📦 Installation

Install via pip:

```bash
pip install synapseconvert

You’ll then have access to the command-line tools:
	•	synapse-upconvert
	•	synapse-downconvert

🛠 Usage

Convert from Excel to JSON (Upconvert)

synapse-upconvert path/to/input.xlsx path/to/output.json

This reads a spreadsheet and produces a properly nested Synapse metadata file.

Convert from JSON to Excel (Downconvert)

synapse-downconvert path/to/input.json path/to/output.xlsx

This flattens a Synapse-style JSON file into a spreadsheet for editing or review.

📄 Spreadsheet Format

The spreadsheet must contain at least the following columns:
	•	collection – the name of the collection (uniform across all rows)
	•	category – name of the group the item belongs to
	•	title, description, etc. – all other metadata fields are treated as item fields
	•	tags – a valid JSON list (e.g., ["Genesis", "Luke"])

A sample blank spreadsheet is available in this repository as blank_synapse_library.xlsx.

🧠 Why This Exists

Synapse is designed to bring remote research libraries directly into Obsidian. Since BiblicalStory cannot make synapse files of all of the repositories that exist, we are providing these tools so that the developers can make synapse libraries of any research library that exists. These libraries can then be added in the synapse settings within Obsidian. 

🔧 Developer Tools

For advanced usage, you can clone this repo and run the commands locally from source:

git clone https://github.com/BiblicalStory/synapseconvert.git
cd synapseconvert
pip install -e .

---


© 2025 BiblicalStory.org. MIT License.

