Postman Collection Guide¶
This guide helps you get started with testing the Nautilus MVP APIs using Postman.
Collection Overview¶
The Postman collection includes pre-configured requests for all API endpoints:
- Health Check
- Data Pool Creation
- Data Append
- Python Execution
- WASM Execution
Setup Instructions¶
1. Import Collection¶
1.1 Locate Collection File¶
- Find
postman/collection.json
in the repository - This file contains all predefined API requests
1.2 Import into Postman¶
1. Open Postman
2. Click "Import" button
3. Drag and drop collection.json OR
4. Click "Upload Files" and select collection.json
2. Configure Environment¶
2.1 Create Environment¶
1. Click "Environments" in Postman
2. Click "Create Environment"
3. Name it "Nautilus MVP" or another suitable name
2.2 Set Variables¶
Using the Collection¶
Health Check¶
- Request:
GET {{BASE_URL}}/health
- Expected Response: "Server is running"
- Purpose: Verify server availability
Create Data Pool¶
- Request:
POST {{BASE_URL}}/create_data_pool
- Body Example:
Append Data¶
- Request:
POST {{BASE_URL}}/append_data
- Body Example:
Execute Python¶
- Request:
POST {{BASE_URL}}/execute_python
- Body Example:
Execute WASM¶
- Request:
POST {{BASE_URL}}/execute_wasm
- Body Example:
{ "github_url": "https://github.com/ntls-io/WASM-Binaries-MVP/blob/master/bin/get_mean_wasm.wasm", "expected_hash": "b5ee81a20256dec2bd3db6e673b11eadae4baf8fafbe68cec1f36517bb569255", "json_schema": { "$schema": "http://json-schema.org/draft-07/schema#", "type": "object", "properties": { "Column_1": { "type": "array", "items": { "type": "number" } }, "Column_2": { "type": "array", "items": { "type": "number" } } }, "required": [ "Column_1", "Column_2" ] } }
Testing Workflows¶
Basic Workflow¶
1. Health Check¶
- Verify server is running
- Check attestation is working
2. Data Operations¶
3. Computation Tests¶
Troubleshooting¶
Common Issues¶
1. SSL/TLS Errors¶
- Solution: Disable SSL verification in Postman
- Note: Only for development/testing
2. Connection Refused¶
- Check server status
- Verify port number
3. Invalid Responses¶
- Verify JSON format
- Check content-type headers
- Validate data structure