🏴 Solidarity with those in public radio 🏴

   _____ __        __  _              ___       __          _
  / ___// /_____ _/ /_(_)___  ____   /   | ____/ /___ ___  (_)___ 
  \__ \/ __/ __ `/ __/ / __ \/ __ \ / /| |/ __  / __ `__ \/ / __ \
 ___/ / /_/ /_/ / /_/ / /_/ / / / // ___ / /_/ / / / / / / / / / /
/____/\__/\__,_/\__/_/\____/_/ /_//_/  |_\__,_/_/ /_/ /_/_/_/ /_/  v.03

About

StationAdmin is currently in beta and is not production ready. We'd love your help testing!

StationAdmin is a constituent relationship management (CRM) system designed to meet the needs of small to medium sized non-profit Radio Stations. It is a suite of tools that bring donors in closer relationship with their donations, station managers and hosts with their donors, and stats and reports for everyone.

StationAdmin is released as a RESTful API along with REACT front-ends for Station Management, Membership Management, Online Donations, and PhoneRoom Volunteers.

It is an open source project, licensed under Creative Commons Attribution-NonCommercial 4.0, and coordinated by KPFA. The project website is COMING SOON!

Requirements

* PHP >= v8.0
* Packages: `php-fpm php-mysql php-cli php-curl php-mbstring php-gd php-intl php-fpm unzip mysql-server mysql-client nginx composer`
* MariaDB >= 10.2 OR MySQL >= 8.0
* NGINX >= 1.14
* Optional Packages `python3-certbot-nginx python3-certbot-dns-cloudflare ssh mosh sshfs snmp phpmyadmin`

Installation

Use the dependency manager composer to install the following.

    composer update
    config passwords in config/database.php

mysql

# install or copy db
CREATE USER '<api_user>'@'localhost' IDENTIFIED BY '<password>';
GRANT ALL PRIVILEGES ON <api_user>.* TO '<database>'@'localhost';

Timeline

Features

This API uses and conforms to the following:

API Resources

All endpoints require authentication except login and POST to donations. Read endpoints are searchable with the use of ?s=query

Resource Create Read Update Delete
Login [✔] [✖] [✖] [✖]
Accounts [✖] [✔] [✖] [✖]
Campaigns [✔] [✔] [✔] [✔]
Donors [✔] [✔] [✔] [✖]
Donors/Foundations [✖] [✖] [✖] [✖]
Donors/Volunteers [✖] [✖] [✖] [✖]
Donors/Staff [✖] [✖] [✖] [✖]
Donations [✔] [✔] [✔] [✔]
Payments [✔] [✔] [✔] [✔]
Premiums [✔] [✔] [✔] [✔]
Premiums/Categories [✔] [✔] [✔] [✔]
Premiums/Vendors [✔] [✔] [✔] [✔]
Receipts [✖] [✔] [✖] [✖]
Shipments [✖] [✔] [✔] [✖]
Shows [✖] [✔] [✖] [✖]
Stats [✔] [✔] [✖] [✖]
Users [✔] [✔] [✔] [✖]
Email [✔] [ – ] [ – ] [ – ]
Mail [✖] [✖] [✖] [✖]
Station [✖] [✖] [✖] [✖]

Examples:

AUTHENTICATION

Via username / password or Google oAuth

AUTHORIZATIN

Handled in the header Authorization with the value Bearer <token>

HTTP response status codes will be returned.

CREATE (POST)

[Donations]

[Email]

[Login]

[Users]

READ (GET)

[Accounts/donors]

[Donations]

[Payments]

[Receipts]

[Shipping]

[Campaigns]

[Premiums]

[Stats]

[Shows]

UPDATE (PUT)

[Shipping]

[Donations]

UPDATE (PATCH)

[Accounts]

DELETE (DELETE)

Data Types - Donations

[Required Section]

Field JSON Limit
firstname string varchar(225)
lastname string varchar(225)
source string ('WebSite','CallCenter','PhoneRoom','StationAdmin','Testing','PaySol','Allegiance')
firstname string
lastname string
address1 string
city string
state string
country string
amount number
postal_code string
installment string ('One-Time','Monthly')

[Optional Section] - NULL is an acceptable value

Field JSON Limit
type string ('Pledge','In-Kind','Vehicle','Bequest','Corporate Match','Stock', 'Donor Advised Fund')
method string ('card','check','cash','stock','in_kind','bank_account')
email string
address2 string
shipping_firstname string
shipping_lastname string
shipping_address1 string
shipping_address2 string
shipping_city string
shipping_state string
shipping_country string
shipping_postal_code string
phone number
cardnumber number (13-19 digits)
exp_month number (2 digits)
exp_year number (4 digits)
cc_securitycode number (3-4 digits)
cardtype string
comments string (1-499 characters)
read_onair boolean
donation_match boolean
add_me boolean
premiums array
premiums_cart array

Support

Sliding-scale support is available from KPFA

License

This project is licensed under the Creative Commons Attribution-NonCommercial 4.0.

Authors and acknowledgment