OsmoWeb API Reference

June 19, 2026 ยท View on GitHub

This document describes the API surface implemented by the OsmoWeb repository at version 0.6.4. It covers the NestJS HTTP and WebSocket interfaces, published TypeScript packages, browser/WASM integration, native Osmocom transports, and repository command-line utilities.

Scope and ownership

SurfaceImplemented hereExternal or host-provided
BTS REST APIYes, in @osmoweb/nestjs-microserviceJWT validation and HTTP server setup come from NestJS and @websdr/nestjs-microservice
Osmocom WebSocket bridgeYesThe host application creates and listens on the HTTP server
TypeScript SDK and Vue componentsYesShared HTTP, WebSocket, WebUSB, logging, and UI primitives come from @websdr/* packages
VTY controllersYesThey connect to native Osmocom daemons
OML, RSL, and Osmux payload protocolsTransported without reinterpretationDefined and consumed by Osmocom
Authentication endpointsNoImported from @websdr/nestjs-microservice through AuthModule
Monitoring receiversNoInfluxDB and Prometheus Pushgateway are external systems
Standalone application/serverNoConsumers embed OsmoModule in a NestJS application

There are no SSE endpoints, GraphQL endpoints, Socket.IO message handlers, or independent RPC server implementations in this repository.

HTTP API

Common behavior

The implemented controller base path is:

/api/v1/osmo/bts

All three operations use JwtAuthGuard from @websdr/nestjs-microservice/auth. The guard accepts a JWT from either:

Cookie: jwt=<token>

or:

Authorization: Bearer <token>

The JWT payload must contain a non-empty sub claim. That value identifies the BTS owner. Tokens are signature- and expiry-checked by Passport and checked against the dependency's in-memory revocation list.

The frontend helpers use apiFetch(), which always sets credentials: "include", so browser cookies are sent when permitted by the deployment's origin and CORS configuration.

No endpoint defines path or query parameters. JSON bodies use Content-Type: application/json.

Nest serializes thrown HttpException objects. In a standard Nest application, an error generally resembles:

{
  "statusCode": 404,
  "message": "No BTS assigned to user"
}

The exact envelope can be changed by host-level exception filters.

BTS data shape

Successful GET and PUT operations return:

interface BtsConfig {
  id: number;
  band: GSMBand;
  ipa: string;
  arfcn: number;
  cell_identity: number;
  osmux_port: number;
}

Supported band values are:

ValueARFCN range accepted by PUT
GSM850128-251
GSM9000-124
EGSM900975-1023
DCS1800512-885
PCS1900512-810

GET /api/v1/osmo/bts

Returns a BTS assignment for the authenticated user. Without a query parameter, the operation returns the user's default assignment.

ItemContract
AuthenticationRequired JWT
HeadersCookie: jwt=... or Authorization: Bearer ...
Path parametersNone
Query parametersOptional instanceId string
Request bodyNone
Success200 OK with BtsConfig

Example:

GET /api/v1/osmo/bts HTTP/1.1
Host: api.example.test
Authorization: Bearer eyJ...

To select a named assignment:

GET /api/v1/osmo/bts?instanceId=browser-tab-1 HTTP/1.1
{
  "id": 0,
  "band": "GSM900",
  "ipa": "26431/0/0",
  "arfcn": 12,
  "cell_identity": 48352,
  "osmux_port": 6001
}

Errors:

StatusMessage or cause
400 Bad RequestJWT is valid but has no sub claim
401 UnauthorizedMissing, invalid, expired, or revoked JWT
404 Not FoundNo BTS assigned to user

Side effects:

  • Removes assignments whose last activity exceeds the manager TTL, five minutes by default.
  • Refreshes lastSeen for the returned assignment.

PUT /api/v1/osmo/bts

Allocates or reuses a BTS assignment and applies its generated configuration to OsmoBSC over VTY.

ItemContract
AuthenticationRequired JWT
HeadersContent-Type: application/json plus JWT cookie or bearer header
Path parametersNone
Query parametersNone
Success200 OK with BtsConfig

Request body:

FieldTypeRequired by implementationBehavior
instanceIdstringNoDistinguishes multiple assignments owned by the same JWT subject; surrounding whitespace is ignored for assignment identity
bandGSMBand stringYesMust be one of the five values listed above
arfcnintegerYes, unless trx[0].arfcn is presentTop-level value takes precedence
trxarray of { id: integer, arfcn?: integer }NoOnly trx[0].arfcn is read by this REST operation

Other JSON fields are rejected by the controller's validation pipe. BSC type, unit id, location area, cell identity, description, and GPRS mode are generated or fixed by the implementation.

Example:

PUT /api/v1/osmo/bts HTTP/1.1
Host: api.example.test
Content-Type: application/json
Cookie: jwt=eyJ...

{
  "instanceId": "browser-tab-1",
  "band": "DCS1800",
  "arfcn": 871
}
{
  "id": 1,
  "band": "DCS1800",
  "ipa": "51183/1/0",
  "arfcn": 871,
  "cell_identity": 36078,
  "osmux_port": 6001
}

Errors:

StatusMessage or cause
400 Bad RequestMissing JWT sub, missing band, missing ARFCN, unsupported GSM band, or ARFCN outside the selected band
401 UnauthorizedMissing, invalid, expired, or revoked JWT
400 Bad RequestDTO validation failure
503 Service UnavailableBSC list synchronization failed
503 Service UnavailableBSC update failed
503 Service UnavailableNo BTS id or Osmux port remains in the configured manager pool
500 Internal Server ErrorOther allocation or processing failure

Side effects:

  1. Expired assignments are released.
  2. For a new assignment, the controller reads show bts and show bts <id> from OsmoBSC and synchronizes reusable BTS ids.
  3. A BTS id, IPA unit id, cell identity, and Osmux port are allocated in memory.
  4. A fixed OsmoBSC BTS/TRX/timeslot configuration is written over VTY.
  5. The BSC configuration is not persisted with write memory.
  6. If BSC configuration fails, a new assignment is released. An existing assignment restores its previous in-memory config and is marked disconnected.

The controller installs a ValidationPipe with transformation, whitelisting, and rejection of non-whitelisted fields. The explicit band and ARFCN compatibility checks run after DTO validation.

DELETE /api/v1/osmo/bts

Releases the authenticated user's default assignment or the assignment selected by instanceId.

ItemContract
AuthenticationRequired JWT
HeadersContent-Type: application/json plus JWT cookie or bearer header
Path parametersNone
Query parametersNone
Request bodyOptional { "instanceId": string }
Success200 OK with { "released": true }

Example:

DELETE /api/v1/osmo/bts HTTP/1.1
Host: api.example.test
Content-Type: application/json
Authorization: Bearer eyJ...

{"instanceId":"browser-tab-1"}
{ "released": true }

Errors:

StatusMessage or cause
400 Bad RequestJWT has no sub claim
401 UnauthorizedMissing, invalid, expired, or revoked JWT
404 Not FoundNo matching assignment exists

Side effects:

  • Removes the assignment from process memory.
  • Makes its BTS id and Osmux port available for reuse.
  • Does not delete or disable the corresponding BTS in OsmoBSC.

WebSocket API

Common connection behavior

The NestJS gateways use the ws adapter and raw WebSocket frames. They do not declare guards, cookies, tokens, required headers, query parameters, or subprotocols. Sec-WebSocket-Protocol is not validated or used by the controllers.

The gateway paths are fixed in decorators:

PathFrame typesNative destination
/wsdr/osmo/controlText JSONIn-process BTS manager
/wsdr/osmo/abis_omlBinaryTCP localhost:3002 by default
/wsdr/osmo/abis_rslBinaryTCP localhost:3003 by default
/wsdr/osmo/mediaInitial text JSON, then binaryUDP localhost:1984 by default

The gateway paths are fixed. The host NestJS application selects the HTTP server address and listening port.

/wsdr/osmo/control

Client request:

{ "event": "get-bts-list" }

Server response:

{
  "event": "get-bts-list",
  "bts": [
    {
      "id": 0,
      "band": "GSM900",
      "ipa": "26431/0/0",
      "arfcn": 12,
      "cell_identity": 48352,
      "osmux_port": 6001
    }
  ]
}

The list contains assignments currently known to the process-local singleton BtsManager.

The only implemented request event is get-bts-list. An object with another event reaches the controller's default branch and receives:

{ "error": { "description": "Unknown request [object Object]" } }

Malformed JSON is not converted into a protocol-level error response. Binary frames are ignored. No external BSC or HLR connection is currently established by this channel.

The protocol types and validators are published from @osmoweb/backend-core/osmorouter/protocol. The separate OsmoParser and OsmoResponse helpers support a four-byte request-id prefix followed by UTF-8 JSON, but the active control gateway does not use that framing; it exchanges plain text JSON.

/wsdr/osmo/abis_oml

This is a bidirectional byte bridge:

  • Each client binary frame represented as a Node.js Buffer is written to the configured OsmoBSC OML TCP socket.
  • Each TCP data chunk is sent as one binary WebSocket message.
  • Text frames are ignored.
  • Closing or failing either side disconnects the TCP client and ultimately closes the WebSocket.

Payload framing and meaning are native IPA/OML semantics; OsmoWeb does not validate or transform the bytes.

/wsdr/osmo/abis_rsl

This has the same behavior as the OML endpoint, but bridges to the configured RSL TCP service. Payloads are native IPA/RSL bytes.

/wsdr/osmo/media

The client must first select an allocated BTS using a text frame:

{ "bts": 0 }

The server looks up that BTS id in the process-local manager and binds a UDP socket to the assignment's osmux_port. It then connects the socket to the configured media service.

After selection:

  • Client binary messages are sent as UDP datagrams to the media service.
  • Each received UDP datagram is sent as a binary WebSocket message.
  • Activity refreshes the assignment's lastSeen timestamp.
  • WebSocket close/error marks the assignment disconnected.

There is no success acknowledgement for BTS selection. Invalid JSON is logged and ignored. If the id does not identify an assignment, the handler continues waiting and does not establish the UDP bridge. Binary messages sent before a valid selection do not establish a media destination.

Authentication integration

Authentication implementation belongs to @websdr/nestjs-microservice, not this repository. OsmoModule imports that package's AuthModule, and the BTS controller consumes its JwtAuthGuard.

The dependency currently provides /api/auth/login, /api/auth/guest, /api/auth/logout, /api/auth/profile, and /api/auth/refresh. These routes are integration dependencies rather than OsmoWeb-owned contracts.

The dependency's cookie is named jwt and is set with:

AttributeValue
HttpOnlytrue
Securetrue only when NODE_ENV=production
SameSitestrict
Path/
Max-AgeDerived from the JWT expiry

The guard also accepts bearer tokens. The JWT sub claim is the only identity field consumed by the OsmoWeb REST controller.

Configuration

NestJS and transport variables

Invalid, missing, zero, or negative numeric values fall back to their defaults. String values are trimmed.

VariableDefaultImplementation use
OSMO_UDP_MEDIA_URIlocalhostUDP Osmux destination host
OSMO_UDP_MEDIA_PORT1984UDP Osmux destination port
OSMO_TCP_ABIS_OML_URIlocalhostOML TCP destination host
OSMO_TCP_ABIS_OML_PORT3002OML TCP destination port
OSMO_TCP_ABIS_RSL_URIlocalhostRSL TCP destination host
OSMO_TCP_ABIS_RSL_PORT3003RSL TCP destination port
OSMO_TCP_HLR_URIlocalhostHLR address used by stats and stored control config
OSMO_TCP_HLR_PORT4258HLR port
OSMO_TCP_BSC_URIlocalhostBSC VTY address used by REST and stats
OSMO_TCP_BSC_PORT4242BSC VTY port

The BSC REST controller constructs one BscController and reuses its VTY client. Host applications should shut down their process normally to close network resources.

JWT variables

These are read by the external WebSDR auth module:

VariableDefault
JWT_SECRETjust_a_demo_secret_key_you_should_change_me
JWT_ALGORITHMHS256
JWT_EXPIRES_IN1h
NODE_ENVControls the JWT cookie's Secure attribute

Frontend URL variables

VariableBehavior
VITE_OSMO_PORTPreferred override for the port used by endpointToOsmoWsUrl()
OSMO_PORTNon-Vite fallback for the same override
VITE_API_URL / API_URLRead by external @websdr/frontend-core to form HTTP and WebSocket base URLs
globalThis.__API_BASE__Runtime API base override provided by the external frontend package

endpointToOsmoWsUrl() returns an existing ws:// or wss:// URL unchanged. For a relative endpoint it delegates to apiWsUrl() and applies the optional Osmo port override.

Statistics variables

VariableDefaultBehavior
STATS_ENABLEDtrueEnables collection only when at least one writer is registered
STATS_INTERVAL_MS10000Poll interval; invalid and non-positive values use the default
OSMO_TCP_BSC_URI / OSMO_TCP_BSC_PORTlocalhost / 4242BSC stats VTY endpoint
OSMO_TCP_HLR_URI / OSMO_TCP_HLR_PORTlocalhost / 4258HLR stats VTY endpoint
OSMO_TCP_MGW_URI / OSMO_TCP_MGW_PORTlocalhost / 4243MGW stats VTY endpoint
OSMO_TCP_MSC_URI / OSMO_TCP_MSC_PORTlocalhost / 4254MSC stats VTY endpoint
OSMO_TCP_STP_URI / OSMO_TCP_STP_PORTlocalhost / 4239STP stats VTY endpoint
INFLUXDB_URLUnsetRegisters the InfluxDB writer
INFLUXDB_ORGUnsetAdds org to a generated v2 write URL
INFLUXDB_BUCKETUnsetAdds bucket to a generated v2 write URL
INFLUXDB_TOKENUnsetSends Authorization: Token <value>
PROMETHEUS_PUSH_URLUnsetRegisters the Pushgateway writer

In-memory BTS manager defaults

SettingDefault
BTS id range0-65535
Osmux port start6001
Osmux port count1024
Assignment inactivity TTL300000 ms
Default bandGSM900
Default ARFCN0

Assignments are process-local and are not persisted.

Published TypeScript API

All packages are ESM and publish TypeScript declarations.

@osmoweb/core

Entrypoints:

ImportExports
@osmoweb/coreEverything from radio and osmo
@osmoweb/core/radioRadio enums, types, conversions, detection, and range helpers
@osmoweb/core/osmoOsmo log conversion and TRX buffer constants

Radio enums and types:

  • RadioTechnology: GSM, LTE, NR
  • GSMBand, LTEBand, NRBand
  • MobileBand
  • ARFCNConfigInput
  • ARFCNConfig
  • FrequencyResult

All frequency values are in kHz.

Functions:

FunctionResult
configureARFCN(input)Resolves technology/band when possible and returns ARFCN plus uplink/downlink frequencies
getSupportedBands(technology)All package-supported bands for a technology
getBandArfcnRange(technology, band){ arfcnStart, arfcnEnd } or undefined for an unknown band
getBandFrequencyRange(technology, band)Uplink/downlink bounds or undefined
gsmArfcnToFrequency(arfcn, band){ uplink, downlink }
gsmFrequencyToArfcn(frequency, band)GSM ARFCN
detectGSMBandFromFrequency(frequency)Matching GSMBand[]; throws when none match
detectGSMBandFromArfcn(arfcn)Matching GSMBand[]; throws when none match
getGSMBandArfcnRange(band)GSM ARFCN bounds
getGSMBandFrequencyRange(band)GSM frequency bounds
getAllGSMBands()All supported GSM bands
lteArfcnToFrequency, lteFrequencyToArfcnLTE conversions
detectLTEBandFromFrequency, detectLTEBandFromArfcnMatching LTE bands; throw when none match
getLTEBandArfcnRange, getLTEBandFrequencyRange, getAllLTEBandsLTE metadata
nrArfcnToFrequency, nrFrequencyToArfcnNR conversions
detectNRBandFromFrequency, detectNRBandFromArfcnMatching NR bands; throw when none match
getNRBandArfcnRange, getNRBandFrequencyRange, getAllNRBandsNR metadata
getJournalLogLevelFromOsmoLogLevel(level)Maps Osmocom levels 1/3/5/7/8 to WebSDR journal levels

configureARFCN() gives arfcn priority over frequency, defaults technology to LTE when neither technology nor a detectable frequency is supplied, and throws when neither ARFCN nor frequency is provided.

Constants:

ConstantValue
OSMO_TRK_CHUNK_SIZE2500
OSMO_TRX_PKT_SIZE5000
OSMO_TRX_PKT_BYTESIZEOSMO_TRX_PKT_SIZE * COMPLEX_INT16_SIZE
COMPLEX_INT16_SIZERe-exported from @websdr/core/common

@osmoweb/backend-core

Entrypoints:

ImportPurpose
@osmoweb/backend-coreRe-exports osmo, osmoctrl, osmorouter, and osmostats
@osmoweb/backend-core/osmoBTS assignment manager
@osmoweb/backend-core/osmoctrlOsmocom VTY controllers and control-protocol types
@osmoweb/backend-core/osmorouterWebSocket bridge router/controllers and configuration
@osmoweb/backend-core/osmorouter/protocolControl message types and validators
@osmoweb/backend-core/osmostatsStats collector and writers

BTS manager

Public functions:

  • getBtsManagerInstance(options?)
  • createIpaFromUuid(uuid, btsId)
  • createCellIdentityFromUuid(uuid, btsId)
  • assignmentToBtsConfig(assignment)

BtsManager methods:

MethodBehavior
syncFromBsc(btsList)Records known BSC ids and marks disconnected, unassigned ids reusable
allocate(uuid, ip, params?)Returns an existing assignment for the owner/instance key or allocates one
updateForUuid(uuid, ip, params)Requires band and ARFCN, then allocates or updates
getByUuid(uuid, instanceId?) / getById(id)Returns an assignment or null
releaseByUuid(...) / releaseById(id)Releases resources and returns whether an assignment existed
markSeen, markSeenByIdRefresh activity; id form also marks connected
markDisconnected, markDisconnectedByIdMarks an assignment disconnected
cleanupExpiredAssignments(now?)Releases assignments older than the TTL
cleanupDisconnectedBscAssignments(btsList)Releases locally disconnected assignments also reported disconnected by BSC
toBtsConfig(assignment)Returns a shallow copy of public BTS config
isAssigned, countAssigned, countFree, dumpStateState inspection

Main types are BtsManagerOptions, IpaUnitId, BtsAssignment, BtsAllocateParams, and BtsUpdateParams.

VTY controllers

Controllers connect to plain TCP Osmocom VTY/telnet ports. No VTY password or TLS option is implemented.

Every controller inherits:

  • connect(), ensureConnected(), disconnect(), isConnected()
  • getUptime(): Promise<number>
  • getStats(): Promise<OsmoBaseStats>
  • vty, exposing the underlying VtyClient instance even though VtyClient is not exported from the package entrypoint

Controller-specific API:

ClassConstructor defaultsPublic operations
BscControllerlocalhost, 4242, debug falsegetStats, getAllBts, getBts, addBts, updateBts, btsExists
HlrControllerlocalhost, 4258, debug falsegetStats, getSubscribers, getSubscriber, addSubscriber, updateSubscriber, subscriberExists, deleteSubscriber
MgwControllerlocalhost, 4243, debug falsegetStats
MscControllerlocalhost, 4254, debug falsegetStats
StpControllerlocalhost, 4239, debug falsegetStats

BscController.updateBts(id, config, persist) applies a fixed baseline BTS and timeslot configuration plus caller-supplied fields. persist=true appends write memory; the default is false. BTS deletion is not implemented.

HlrController subscriber writes issue native VTY commands. Supported 2G algorithm names are comp128v1, comp128v2, comp128v3, and xor-2g; recognized 3G names are milenage, tuak, and xor-3g, although the emitted 3G command currently uses milenage.

Exported data types include BscBtsConfig, BscBtsTrxConfig, BscBtsInfo, all controller stats types, HlrSubscriber, CtrlCommand, CtrlResponse, CtrlTrapEvent, OsmoComponent, and OSMO_COMPONENTS.

Router and protocol

Router provides:

  • register(token, controllerClass)
  • init(osmoParams)
  • resolve(token)
  • to(uri, port), which resolves the final path segment; port is unused

Built-in tokens are control, abis_rsl, abis_oml, and media. Unknown tokens resolve to DefaultController, which only logs the missing URL.

Exported router classes are Router, AbisOmlController, AbisRslController, ControlController, and MediaController. Exported configuration includes OsmoServices, osmoServiceAddrMap, osmoDefaultParams, OsmoParams, and BtsConfig.

The protocol subpath exports validateOsmoRequest() and validateOsmoResponse() plus the request/response types. Validators return the input object when recognized and undefined otherwise.

Statistics

StatsCollector.addController(id, controller) registers a VTY controller. collect() connects sequentially, gathers stats, disconnects, and returns one CollectedStat per controller. Failures become:

{
  "id": "osmo-bsc",
  "stats": { "status": "disconnected", "uptime": 0 },
  "timestamp": 1710000000000
}

InfluxAdapter.write() sends InfluxDB line protocol with measurement osmo_stats. PrometheusAdapter.write() sends text exposition data, normally to /metrics/job/<service>. Both writers log receiver failures instead of throwing them to the caller.

Other exports are forEachOsmoService, forEachCollectedStat, CollectedStat, CollectedStats, StatsWriter, InfluxOptions, and PrometheusOptions.

@osmoweb/nestjs-microservice

Actual published entrypoints:

ImportExports
@osmoweb/nestjs-microserviceOsmoModule, OSMO_PARAMS
@osmoweb/nestjs-microservice/osmoOsmoModule, OSMO_PARAMS

OsmoModule registers the REST controller, four WebSocket gateways, router, logging integration, auth integration, and stats module. It is an embeddable Nest module and does not bootstrap or listen on a port.

Auth and users APIs are imported directly from @websdr/nestjs-microservice.

@osmoweb/frontend-core

Entrypoints:

ImportPurpose
@osmoweb/frontend-coreRe-exports osmo and services
@osmoweb/frontend-core/servicesBTS HTTP helpers
@osmoweb/frontend-core/osmoBrowser worker, WebSocket, WebUSB, and WASM bridge

HTTP helpers:

getBts(instanceId?: string): Promise<BtsConfig>
updateBts(cfg?: BtsUpdateInput): Promise<BtsConfig>
releaseBts(instanceId?: string): Promise<{ released: boolean }>

They delegate URL, cookie, and non-2xx handling to the external @websdr/frontend-core/services package.

Manager API:

ExportMain contract
getOsmoTrxManagerInstance(params?)Returns the process-global manager instance
OsmoTrxManagerAbstract manager contract
OsmoTrxManagerWorkerWorker-backed implementation
OsmoTrxWorkerWorker-side WebUSB/WASM/WebSocket runtime
OsmoTrxWorkerInitialParamsDefault WebSocket paths
endpointToOsmoWsUrl(endpoint)Converts a relative API endpoint to ws:/wss:

OsmoTrxManager methods:

  • open_bts(bts, band, arfcn, ip_access_uid, osmux_port)
  • open_usb(vendorId?, productId?)
  • open_ws(urls)
  • close()
  • getBtsStats(group)
  • setParameter(param, value)
  • startWorker(params), stopWorker()
  • start(params), stop()

OsmoTrxManagerWorker additionally exposes close_usb() and close_ws(). Callback properties are onWriteLog, onLog, and onChangeParameter.

BtsStatsGroup accepts stats, rate-counters, bts, trx, transceiver, or websdr.

OsmoTrxWorker public members include:

  • fd, urls
  • openWs, openBasicWS, closeWs
  • openUsbByVidPid, openUsb, closeUsb
  • openBts, close, start, stop, destroy
  • sendOmlBuffer, sendRslBuffer
  • WebUSB/WASM/WebSocket callback methods such as onReceiveData, onMediaData, onAbisData, and the onWS* handlers
  • setParameter("urls" | "bts", value); other parameter names return false

The worker's openBasicWS() opens OML, RSL, and media channels. It does not open the control channel.

WASM bridge

Exports include:

  • initOsmo(overrides?)
  • Osmo
  • OsmoBands, OsmoBandsKeys, IPAccessProto
  • Native callbacks on_start, on_stop, on_set_rx_frequency, on_set_tx_frequency, on_write_samples, ws_osmux_deliver_cb, ws_ipa_send, write_log, on_log, start_timer_interval, and ws_rsl_connect_cb

Osmo methods include init, applyBtsConfig, deinit, sendSchedulerTimer, startSchedulerTimer, stopSchedulerTimer, sendRxShortData, getTxShortVector, sendMediaData, sendAbisData, getBtsStats, and debug.

The bundled declaration also defines OsmoTrxModule, the Emscripten module contract for native functions:

  • _osmobts_init
  • _osmobts_apply
  • _osmobts_push_rx_short_vector
  • _osmobts_get_tx_short_vector
  • _osmobts_get_stats
  • _ws_osmux_push_raw_data
  • _ws_ipa_push_raw_data
  • _on_sched_timer

The generated module itself is bundled for internal use but is not a package subpath export.

@osmoweb/vue3-components

Entrypoints:

ImportExports
@osmoweb/vue3-componentsComponents and their public types
@osmoweb/vue3-components/componentsSame component exports
@osmoweb/vue3-components/styles/*Compiled CSS assets

BtsConfig

Props:

PropTypeDefault
btsBtsParamsundefined
supportedTechnologiesRadioTechnology[][RadioTechnology.GSM]
searchablebooleanfalse

Events:

  • submit(config: BtsParams)
  • cancel()

BtsParams contains optional technology, band, arfcn, uplinkFrequency, and downlinkFrequency. Frequencies are kHz.

BtsInput

Props:

PropTypeDefault
btsBtsParamsundefined
supportedTechnologiesRadioTechnology[]Passed through to BtsConfig
placeholderstringClick to configure BTS
sizeexternal SizeTypemedium
btsStatenot-configured | configured | connected | disconnectedundefined
disabledbooleanfalse
searchablebooleanfalse

Events:

  • update(config: BtsParams)
  • cancel()

Native and hardware protocols

Osmocom VTY

The backend VTY client uses a TCP socket with minimal telnet negotiation. It sends CRLF-terminated commands, detects Osmo...> or Osmo...# prompts, and serializes queued commands. Default connect timeout is 5000 ms and most command timeouts are 5000 ms.

This is an integrating API: command syntax and output formats belong to the corresponding Osmocom daemon. OsmoWeb implements parsers and command sequences for the controller methods listed above.

IPA OML and RSL

The WebSocket bridge forwards native binary IPA/OML and IPA/RSL streams over TCP. The browser WASM bridge uses stream selector 1 for OML and 2 for RSL.

Osmux media

Media WebSocket binary messages map one-to-one to UDP datagrams after BTS selection. The server binds the UDP socket to the allocated osmux_port and connects it to the configured media endpoint.

WebUSB SDR

The browser runtime uses WebUsbSourceSink and device management from the external @websdr/frontend-core/webusb package. OsmoWeb configures complex signed 16-bit IQ data, sample rate 1,083,333, packet size 5000 complex samples, and default RX/TX radio parameters. Device discovery, USB control commands, and the underlying firmware protocol are external contracts.

Browser WebUSB access requires the browser's WebUSB conditions, including a secure context and user-mediated device selection where applicable.

Command-line interfaces

No package defines a bin entry or installs a product CLI.

Repository scripts provide development and operations commands:

CommandPurpose
npm run buildBuilds all workspaces
npm run testRuns workspace tests
npm run test:allRuns the root Vitest configuration
npm run test:watchRuns Vitest in watch mode
npm run test:coverageRuns coverage
npm run docs:diagramsRenders Mermaid files under docs/
npm run docs:diagrams:ubuntuRenders through the configured AppArmor profile
node scripts/render-mermaid.js [docs-root]Direct diagram-renderer invocation; default root is docs
cd test-apps && npm run test:bscManual BSC VTY integration script; changes BSC configuration
cd test-apps && npm run test:hlrManual HLR CRUD script; changes subscriber data
cd test-apps && npm run test:mscReads MSC stats
cd test-apps && npm run test:mgwReads MGW stats
cd docker && ./start_stats.shStarts monitoring containers
cd docker && ./stop_stats.shStops monitoring containers

The manual test applications use hard-coded localhost VTY destinations and do not accept command-line flags.

External outbound APIs

These calls originate in OsmoWeb but target systems not implemented here:

DestinationRequest
InfluxDB 2.xPOST line protocol to the configured write URL, or generated /api/v2/write?...&precision=ns
Prometheus PushgatewayPOST text exposition format to a configured metrics URL, or generated /metrics/job/<service>
OsmoBSC OMLRaw TCP to configured host/port
OsmoBSC RSLRaw TCP to configured host/port
Osmux media serviceRaw UDP to configured host/port
Osmocom VTY servicesTelnet-like TCP commands to BSC, HLR, MGW, MSC, and STP

Receiver-specific response bodies are not exposed as OsmoWeb API contracts. InfluxDB non-2xx responses and network failures are logged. Pushgateway fetch rejections are logged; HTTP status codes are not otherwise interpreted.