Jump to content

SimTX API/Packets/CatalogUpload

From SimTX Wiki
CatalogUpload
Frame ClientFrame, field 38
Member catalog_upload
Direction Client → server
Session Control (catalog)
Roles ROLE_CONTROL, authenticated.
Permission catalog.publish
Answered by CatalogUploadResult or Error
Answers
Defined in control.proto

CatalogUpload publishes an extension or preset to the server's extension catalog, or a new revision of an entry the account already owns.

Definition[edit | edit source]

message CatalogUpload {
  int64 request_id = 1;
  string kind = 2;
  string name = 3;
  string description = 4;
  repeated string categories = 5;
  repeated CatalogFile files = 6;
}

Fields[edit | edit source]

# Field Type Description
1 request_id int64 Nonzero; echoed in the CatalogUploadResult or Error.
2 kind string extension or preset. At most 16 characters.
3 name string Entry name, 1 to 64 characters after trimming. Unique per server, compared without regard to case.
4 description string At most 500 characters.
5 categories repeated string 0 to 12 categories, each 1 to 32 characters, no commas or control characters.
6 files repeated CatalogFile 1 to 64 files; a preset is exactly one .stxpreset file.

Validation[edit | edit source]

The server checks the upload against the upload rules. A refused upload is answered with Error whose message names the first problem found:

  • FORBIDDEN: Publishing requires catalog.publish, or the name belongs to another account (An item named 'X' already exists (by Author)).
  • INVALID_REQUEST: an unknown kind, a preset that is not exactly one .stxpreset file, an invalid path, name, category or manifest. Manifest errors are passed through verbatim.
  • LIMIT_REACHED: Catalog entry quota reached (32), Catalog storage quota reached, Server catalog storage is full.
  • UNAVAILABLE: This server has no catalog, The catalog is temporarily unavailable.
  • INTERNAL: Could not store the item.

Show the message to the user; it says what to fix.

Revisions[edit | edit source]

Uploading an entry with the name of an entry the same account already owns replaces it: the ID stays, the revision increases, and the result has updated = true. Names are compared without regard to case.

See also[edit | edit source]

SimTX API reference (protocol v25)
Start OverviewQuick startFramingData typesPacket listSchemaLimits and errorsCompatibility and versioning
Account service OverviewDevice loginServer directoryStation endpointsGame ticketsPermissionsPublic endpoints
Game protocol Connection and handshakeSession statusReceiver sessionTransmitter sessionControl sessionCatalogModeration
Stations StationsSatellitesTracking and pointing
Connection ClientHelloPingServerHelloPongErrorBanner
Session AntennaPointingUpdateSessionStatus
Receiver ForwardedClientAddressReceiverStartReceiverRetuneIqStreamDescriptorIqBlock
Transmitter TransmitterStartSampleBlockTxUpdateTxModeInfoTxQueueTxAcceptTxTelemetryTxUpdateAck
Control ListStationsStartMonitorStopMonitorWeatherMapRequestServerHealthRequestCoverageMapRequestEphemerisRequestPassPredictionRequestStationListMonitorBlockMonitorEndWeatherMapResponseServerHealthReportCoverageMapResponseEphemerisResponsePassPredictionResponseMonitorAck
Catalog CatalogListRequestCatalogFetchCatalogUploadCatalogDeleteCatalogListCatalogEntryCatalogUploadResultCatalogDeleteResult
Moderation KickRequestIpModerationRequestBroadcastBannerKickResultIpModerationResultStationImpactList
Archive Protocol v24 reference