定制 queenaurelia/sota-api-client 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

queenaurelia/sota-api-client

最新稳定版本:v1.0

Composer 安装命令:

composer require queenaurelia/sota-api-client

包简介

A PHP client for the SOTA (Summits On The Air) API

README 文档

README

A client for integrating with the Summits On The Air (SOTA) database.

Quickstart

<?php

declare(strict_types=1);

use QueenAurelia\SOTA_Client\Client;
use QueenAurelia\SOTA_Client\Activation;
use QueenAurelia\SOTA_Client\Chase;
use QueenAurelia\SOTA_Client\Qso;

$client = new Client(
    [
        'client_id' => 'my-client-id', # You get this from the SOTA people
        'username' => 'w1aw', # Your SOTA database username, will probably be your callsign
        'password' => 'my-password', # Your SOTA database password
    ]
);

$qso = new Qso()
    ->callsign("K0GQ") # Call sign of the station contacted
    ->date("2025-06-18") # Date of the QSO
    ->time("23:23") # Time of the QSO
    ->mode("SSB") # Mode used to make the QSO
    ->band("14.310Mhz") # Band the QSO was made on
    ->s2sSummitCode("W0I/IA-001"); # Remote summit for S2S (summit-to-summit) QSOs

$activation = new Activation()
    ->date("2025-06-18") # Date of the activation
    ->ownCallsign("w1aw") # Your call sign
    ->summit("W0I/IA-002") # Summit you're activating
    ->qsos([$qso]);

$chase = new Chase() 
    ->date("2025-06-18") # Date of the chase
    ->timeStr("23:23") # Time of the chase
    ->ownCallsign('W1AW') # Your callsign
    ->otherCallsign('K0HAM') # Call sign of the station contacted
    ->summitCode("W0I/IA-003") # Location of activator or remote summit if S2S
    ->s2sSummitCode("W0I/IA-002") # Location of user/local summit for S2S
    ->band("14.310MHz") # Band the contact was made on
    ->mode("SSB") # Mode used to make the contact
    ->comments("59"); # comments regarding the contact

$client->addActivation($activation);
$client->addChase($chase);
$client->upload(); # Upload activation and chase to SOTA

Objects

Client

This is the class that actually uploads data to the SOTA database.

Methods:

constructor

Initializes the client. Parameters:

  • client_id This is the client ID assigned to you by the SOTA database admins.
  • username Your SOTA database username. Generally your callsign.
  • password Your SOTA database password.

addActivation()

Add an Activation to be uploaded. This may be called multiple times to add multiple activations.

addChase()

Add a Chase to be uploaded. This may be called multiple times to add multiple chases.

upload()

Upload the current set of records to the SOTA database. Note that S2S QSOs will automatically be extracted from the set of QSOs in the activation.

Activation

This represents a SOTA activation. It includes one or more QSOs.

<?php

use QueenAurelia\SOTA_Client\Activation;
use QueenAurelia\SOTA_Client\Qso;

$activation = new Activation()
    ->date("2025-06-18") # Date of the activation
    ->ownCallsign("w1aw") # Your call sign
    ->summit("W0I/IA-002") # Summit you're activating
    ->qsos([new Qso()->
        ->callsign("K0GQ") # Call sign of the station contacted
        ->date("2025-06-18") # Date of the QSO
        ->time("23:23") # Time of the QSO
        ->mode("SSB") # Mode used to make the QSO
        ->band("14.310Mhz") # Band the QSO was made on
    ]);

Chase

This represents a chase (i.e. a spot) of a SOTA activation

Usage:

<?php

use QueenAurelia\SOTA_Client\Qso;

declare(strict_types=1);

$chase = new Chase() 
    ->date("2025-06-18") # Date of the chase
    ->timeStr("23:23") # Time of the chase
    ->ownCallsign('W1AW') # Your callsign
    ->otherCallsign('K0HAM') # Call sign of the station contacted
    ->summitCode("W0I/IA-003") # Location of activator or remote summit if S2S
    ->s2sSummitCode("W0I/IA-002") # Location of user/local summit for S2S
    ->band("14.310MHz") # Band the contact was made on
    ->mode("SSB") # Mode used to make the contact
    ->comments("59"); # comments regarding the contact

Qso

This represents a QSO (i.e. amateur radio contact) made during a SOTA activation.

Usage:

<?php

use QueenAurelia\SOTA_Client\Qso;

declare(strict_types=1);


$qso = new Qso()
    ->callsign("K0GQ") # Call sign of the station contacted
    ->date("2025-06-18") # Date of the QSO
    ->time("23:23") # Time of the QSO
    ->mode("SSB") # Mode used to make the QSO
    ->band("14.310Mhz") # Band the QSO was made on
    ->s2sSummitCode("W0I/IA-001") # Remote summit for S2S (summit-to-summit) QSOs
    ->comments("59"); # Comments regarding the QSO

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: AGPL-3.0-or-later
  • 更新时间: 2025-06-18