saascity

package module
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2026 License: MIT Imports: 9 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

saascity-go

Go Reference

Zero-dependency Go SDK and CLI for SaaSCity — the curated SaaS & AI launch directory on a live isometric city map.

Calls SaaSCity's keyless Streamable HTTP Model Context Protocol (MCP) endpoint (https://saascity.io/api/mcp) and NLWeb discovery endpoint (https://saascity.io/ask) using only the Go standard library (net/http, encoding/json).

Install

go get github.com/best-directories/saascity-go@v1.0.0

Or install the standalone Go CLI:

go install github.com/best-directories/saascity-go/cmd/saascity@v1.0.0

Usage

package main

import (
	"context"
	"fmt"
	"log"

	saascity "github.com/best-directories/saascity-go"
)

func main() {
	ctx := context.Background()
	client := saascity.NewClient()

	// 1. Run a 16-point homepage launch readiness audit (no API key required)
	report, err := client.CheckLaunchReadiness(ctx, "https://acme.dev")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("Readiness: %d/100 (%s)\n", report.Score, report.Verdict)

	// 2. Filter 1,600+ startup, SaaS & AI directories by DR, dofollow & pricing
	dirs, err := client.FindLaunchDirectories(ctx, saascity.DirectoryFilter{
		Category:           "SaaS Tools",
		DofollowOnly:       true,
		FreeOrFreemiumOnly: true,
		MinDR:              40,
		Limit:              10,
	})
	if err != nil {
		log.Fatal(err)
	}
	for _, d := range dirs.Directories {
		fmt.Printf("- %s (%s) DR %d [%s]\n", d.Name, d.Domain, d.DR, d.SubmitURL)
	}
}

License

MIT — see LICENSE.

Documentation

Overview

Package saascity provides a zero-dependency Go client for SaaSCity's keyless Model Context Protocol (MCP) server, NLWeb search endpoint, and Maker API.

SaaSCity (https://saascity.io) is the curated launch directory for SaaS and AI tools on a live isometric city map, backed by a verified dataset of 1,600+ startup, SaaS, and AI directories with Ahrefs Domain Rating (DR), dofollow/nofollow link verification, and pricing.

Keyless Endpoints

Read-only launch readiness checks, directory filtering, badge checks, and backlink verification call https://saascity.io/api/mcp over JSON-RPC 2.0 (MCP protocol version 2025-11-25) with zero API keys or registration required:

Quick Start

client := saascity.NewClient()
audit, err := client.CheckLaunchReadiness(ctx, "https://acme.dev")
if err != nil {
    log.Fatal(err)
}
fmt.Printf("Score: %d/100 (%s)\n", audit.Score, audit.Verdict)

Index

Constants

View Source
const (
	// DefaultBaseURL is the production SaaSCity base URL (https://saascity.io).
	DefaultBaseURL = "https://saascity.io"
	// MCPProtocolVersion is the stateless Streamable HTTP MCP version supported by SaaSCity.
	MCPProtocolVersion = "2025-11-25"
	// Version is the saascity-go SDK version.
	Version = "1.0.0"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AuditCheck

type AuditCheck struct {
	ID       string `json:"id,omitempty"`
	Label    string `json:"label"`
	Status   string `json:"status"`
	Detail   string `json:"detail"`
	Critical bool   `json:"critical,omitempty"`
}

AuditCheck describes a single check in a 16-point SaaSCity homepage readiness audit.

type BadgeCheckResult

type BadgeCheckResult struct {
	Found        bool   `json:"found"`
	Code         string `json:"code,omitempty"`
	Message      string `json:"message,omitempty"`
	BadgeSnippet string `json:"badgeSnippet,omitempty"`
}

BadgeCheckResult reports whether the Featured on SaaSCity badge is live on a URL.

type Client

type Client struct {
	BaseURL    string
	APIKey     string
	HTTPClient *http.Client
	UserAgent  string
}

Client communicates with SaaSCity's keyless MCP server (https://saascity.io/api/mcp), NLWeb search endpoint (https://saascity.io/ask), and authenticated Maker API.

func NewClient

func NewClient(opts ...Option) *Client

NewClient constructs a SaaSCity Client targeting https://saascity.io.

func (*Client) AskNLWeb

func (c *Client) AskNLWeb(ctx context.Context, query string) ([]NLWebItem, error)

AskNLWeb queries SaaSCity's NLWeb natural-language discovery endpoint (/ask).

func (*Client) CallTool

func (c *Client) CallTool(ctx context.Context, toolName string, arguments map[string]any) (*ToolResponse, error)

CallTool invokes any keyless SaaSCity MCP tool by name on POST /api/mcp. Full tool documentation is available at https://saascity.io/mcp.

func (*Client) CheckBadge

func (c *Client) CheckBadge(ctx context.Context, targetURL string) (*BadgeCheckResult, error)

CheckBadge checks whether targetURL displays a verified SaaSCity launch badge.

func (*Client) CheckLaunchReadiness

func (c *Client) CheckLaunchReadiness(ctx context.Context, targetURL string) (*LaunchReadinessReport, error)

CheckLaunchReadiness runs SaaSCity's 16-point launch readiness audit against targetURL.

func (*Client) FindLaunchDirectories

func (c *Client) FindLaunchDirectories(ctx context.Context, filter DirectoryFilter) (*DirectorySearchResult, error)

FindLaunchDirectories filters 1,600+ launch directories by category, DR, link type, and pricing.

type DirectoryEntry

type DirectoryEntry struct {
	Name          string `json:"name"`
	Domain        string `json:"domain"`
	DR            int    `json:"dr"`
	LinkType      string `json:"linkType"`
	Pricing       string `json:"pricing"`
	Category      string `json:"category"`
	BadgeExchange bool   `json:"badgeExchange"`
	SubmitURL     string `json:"submitUrl"`
	Note          string `json:"note,omitempty"`
}

DirectoryEntry represents a startup, SaaS, or AI launch directory in SaaSCity's dataset.

type DirectoryFilter

type DirectoryFilter struct {
	Query                string
	Category             string
	MinDR                int
	DofollowOnly         bool
	FreeOrFreemiumOnly   bool
	ExcludeBadgeExchange bool
	Limit                int
	Offset               int
}

DirectoryFilter filters SaaSCity's 1,600+ verified launch directories dataset.

type DirectorySearchResult

type DirectorySearchResult struct {
	Total         int              `json:"total"`
	Offset        int              `json:"offset"`
	Directories   []DirectoryEntry `json:"directories"`
	DataUpdatedAt string           `json:"dataUpdatedAt,omitempty"`
	Attribution   string           `json:"attribution,omitempty"`
}

DirectorySearchResult wraps paginated directory matches from find_launch_directories.

type LaunchReadinessReport

type LaunchReadinessReport struct {
	URL           string       `json:"url"`
	FinalURL      string       `json:"finalUrl,omitempty"`
	Score         int          `json:"score"`
	Verdict       string       `json:"verdict"`
	HTTPStatus    int          `json:"httpStatus,omitempty"`
	ResponseMs    int          `json:"responseMs,omitempty"`
	SaaSCityBadge bool         `json:"saascityBadge,omitempty"`
	Checks        []AuditCheck `json:"checks"`
}

LaunchReadinessReport contains the 0-100 score, verdict, and individual SEO/OG/technical checks.

type NLWebItem

type NLWebItem struct {
	Name        string  `json:"name"`
	Description string  `json:"description"`
	URL         string  `json:"url"`
	Score       float64 `json:"score,omitempty"`
}

NLWebItem represents a natural-language search result from GET https://saascity.io/ask.

type Option

type Option func(*Client)

Option customizes a Client.

func WithAPIKey

func WithAPIKey(apiKey string) Option

WithAPIKey sets a SaaSCity Maker API key (scm_live_...) for Maker API endpoints.

func WithBaseURL

func WithBaseURL(baseURL string) Option

WithBaseURL overrides the SaaSCity base URL (useful for testing).

func WithHTTPClient

func WithHTTPClient(hc *http.Client) Option

WithHTTPClient provides a custom *http.Client.

type ToolResponse

type ToolResponse struct {
	Text       string          `json:"text"`
	Structured json.RawMessage `json:"structuredContent,omitempty"`
}

ToolResponse holds both the human-readable text output and typed JSON structuredContent returned by https://saascity.io/api/mcp.

Directories

Path Synopsis
cmd
saascity command
Command saascity runs SaaSCity homepage launch readiness checks and directory queries from Go.
Command saascity runs SaaSCity homepage launch readiness checks and directory queries from Go.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL