{
  "openapi": "3.1.0",
  "info": {
    "title": "START_PREISBLATT (NB)",
    "version": "202610",
    "description": "Das Ereignis `START_PREISBLATT` der Marktrolle NB als eigenständige Spezifikation, abgeleitet aus der Auslöser-API der Formatversion 202610. Genau ein Pfad: `POST /inbound`; das Ereignis ergibt sich aus `zusatzdaten.eventname` im Rumpf."
  },
  "servers": [
    {
      "description": "Fake Env",
      "url": "https://api.macoapp.de"
    }
  ],
  "tags": [
    {
      "name": "START_PREISBLATT"
    }
  ],
  "paths": {
    "/inbound": {
      "post": {
        "deprecated": false,
        "description": "Trigger-Event **START_PREISBLATT** der Marktrolle NB.\n\n**Startet diese Rollensichten** (2):\n\n- [Übermittlung Preisblatt NB an LF — NB (AWH Sperrprozesse Gas)](/prozessdoku/202610/NB/awh-sperrprozesse-gas-ubermittlung-preisblatt-nb-an-lf)\n- [Übermittlung Preisblatt NB an LF — NB (GPKE Teil 2)](/prozessdoku/202610/NB/GPKE-Teil2-uebermittlung-preisblatt-nb-an-lf)\n\n<a href=\"/apis/einzeln/202610/nb/START_PREISBLATT.json\" data-maco=\"einzelschema\" download target=\"_blank\">Schema nur dieses Ereignisses herunterladen</a> (OpenAPI, JSON).\n\n<Hinweisbereich>\n\nDer Aufruf geht tatsächlich an `POST /inbound`; das Event ergibt sich aus `zusatzdaten.eventname` im Rumpf. Diese Seite trennt eine von 104 Rumpfvarianten heraus, damit sie einzeln lesbar und ausprobierbar sind.\n\n</Hinweisbereich>",
        "operationId": "trigger_NB_START_PREISBLATT",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NB_START_PREISBLATT"
              }
            }
          }
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/event_responses_success"
                }
              }
            },
            "description": "Erfolg | Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/event_response_fail"
                }
              }
            },
            "description": "Fehler | Fail"
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "summary": "START_PREISBLATT (NB)",
        "tags": [
          "START_PREISBLATT"
        ],
        "x-actual-endpoint": "POST /inbound",
        "x-event-source": "event/202610/[NB]_START_PREISBLATT.yaml",
        "x-handbuchsatz": true
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearer": {
        "scheme": "bearer",
        "type": "http"
      }
    },
    "schemas": {
      "NB_START_PREISBLATT": {
        "properties": {
          "stammdaten": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/PI_27003__stammdaten"
              }
            ]
          },
          "transaktionsdaten": {
            "properties": {
              "absender": {
                "properties": {
                  "rollencodenummer": {
                    "$ref": "#/components/schemas/rollencodenummer"
                  }
                },
                "type": "object"
              },
              "empfaenger": {
                "properties": {
                  "rollencodenummer": {
                    "$ref": "#/components/schemas/rollencodenummer"
                  }
                },
                "type": "object"
              },
              "kategorie": {
                "$ref": "#/components/schemas/kategorie"
              },
              "pruefidentifikator": {
                "description": "Wird dynamisch im Event-Prozess ermittelt. Ein vom Sender mitgegebener Wert wird ignoriert. Im Topic mögliche Prüfis — 27003.",
                "examples": [
                  "27003"
                ]
              },
              "sparte": {
                "$ref": "#/components/schemas/sparte"
              }
            },
            "required": [
              "absender",
              "empfaenger",
              "kategorie",
              "sparte"
            ],
            "type": "object"
          },
          "zusatzdaten": {
            "properties": {
              "eventname": {
                "const": "START_PREISBLATT",
                "default": "START_PREISBLATT",
                "type": "string"
              },
              "prozessId": {
                "type": "string"
              }
            },
            "required": [
              "prozessId",
              "eventname"
            ],
            "type": "object"
          }
        },
        "required": [
          "stammdaten",
          "transaktionsdaten",
          "zusatzdaten"
        ],
        "type": "object"
      },
      "PI_27003__stammdaten": {
        "properties": {
          "PREISBLATT": {
            "items": {
              "$ref": "#/components/schemas/PI_27003__stammdaten__PREISBLATT"
            },
            "type": "array"
          }
        },
        "required": [
          "PREISBLATT"
        ],
        "type": "object",
        "title": "27003"
      },
      "PI_27003__stammdaten__PREISBLATT": {
        "properties": {
          "gueltigkeit": {
            "$ref": "#/components/schemas/PI_27003__stammdaten__PREISBLATT__gueltigkeit"
          },
          "preisNetzbetreiberCodenummer": {
            "$ref": "#/components/schemas/preisNetzbetreiberCodenummer",
            "x-edifact-segment": [
              "SG1.RFF+Z56"
            ]
          },
          "preispositionen": {
            "items": {
              "$ref": "#/components/schemas/PI_27003__stammdaten__PREISBLATT__preispositionen"
            },
            "type": "array"
          }
        },
        "required": [
          "gueltigkeit"
        ],
        "type": "object"
      },
      "PI_27003__stammdaten__PREISBLATT__gueltigkeit": {
        "properties": {
          "startdatum": {
            "$ref": "#/components/schemas/startdatum",
            "x-edifact-segment": [
              "DTM+157"
            ]
          }
        },
        "required": [
          "startdatum"
        ],
        "type": "object"
      },
      "PI_27003__stammdaten__PREISBLATT__preispositionen": {
        "properties": {
          "artikelId": {
            "$ref": "#/components/schemas/artikelId",
            "x-edifact-segment": [
              "SG17.PGI+9.SG36.LIN",
              "SG17.PGI+Z01.SG36.LIN"
            ]
          },
          "positionsnummer": {
            "$ref": "#/components/schemas/positionsnummer",
            "x-edifact-segment": [
              "SG17.PGI+9.SG36.LIN",
              "SG17.PGI+Z01.SG36.LIN"
            ]
          },
          "preisstaffeln": {
            "items": {
              "$ref": "#/components/schemas/PI_27003__stammdaten__PREISBLATT__preispositionen__preisstaffeln"
            },
            "type": "array"
          },
          "zeitbasis": {
            "$ref": "#/components/schemas/zeitbasis",
            "x-edifact-segment": [
              "SG17.PGI+9.SG36.LIN.SG40.PRI+CAL",
              "SG17.PGI+Z01.SG36.LIN.SG40.PRI+CAL"
            ]
          }
        },
        "type": "object"
      },
      "PI_27003__stammdaten__PREISBLATT__preispositionen__preisstaffeln": {
        "properties": {
          "einheitspreis": {
            "$ref": "#/components/schemas/einheitspreis",
            "x-edifact-segment": [
              "SG17.PGI+9.SG36.LIN.SG40.PRI+CAL",
              "SG17.PGI+Z01.SG36.LIN.SG40.PRI+CAL"
            ]
          },
          "staffelgrenzeBis": {
            "$ref": "#/components/schemas/staffelgrenzeBis",
            "x-edifact-segment": [
              "SG17.PGI+Z01.SG36.LIN.SG40.PRI+CAL.RNG+10+KWH"
            ]
          },
          "staffelgrenzeVon": {
            "$ref": "#/components/schemas/staffelgrenzeVon",
            "x-edifact-segment": [
              "SG17.PGI+Z01.SG36.LIN.SG40.PRI+CAL.RNG+10+KWH"
            ]
          }
        },
        "type": "object"
      },
      "Sparte": {
        "description": "Sparte",
        "enum": [
          "STROM",
          "GAS",
          "FERNWAERME",
          "NAHWAERME",
          "WASSER",
          "ABWASSER"
        ],
        "title": "Sparte",
        "type": "string"
      },
      "Zeiteinheit": {
        "description": "Zeiteinheit",
        "enum": [
          "SEKUNDE",
          "MINUTE",
          "STUNDE",
          "VIERTEL_STUNDE",
          "TAG",
          "WOCHE",
          "MONAT",
          "QUARTAL",
          "HALBJAHR",
          "JAHR"
        ],
        "title": "Zeiteinheit",
        "type": "string"
      },
      "artikelId": {
        "description": "artikelId",
        "type": "string"
      },
      "einheitspreis": {
        "description": "einheitspreis",
        "format": "float",
        "type": "number"
      },
      "event_response_fail": {
        "description": "Fehlermeldung auf Prozessdaten API Aufruf | Error message on process data API call",
        "properties": {
          "errorCode": {
            "description": "Error identifier",
            "example": "400",
            "type": "string"
          },
          "message": {
            "description": "Technische Meldung | Technische Meldung",
            "example": "Validation Failed",
            "type": "string"
          }
        },
        "type": "object"
      },
      "event_responses_success": {
        "description": "Erfolgsmeldung auf Prozessdaten API Aufruf | Success message on process data API call",
        "properties": {
          "businessKey": {
            "description": "Einzigartige Kennung des Geschäftsprozesses | Unique identifier of the business process",
            "format": "uuid",
            "type": "string"
          },
          "message": {
            "description": "Nachricht mit Details zum ausgelösten Event | Message with details about the triggered event",
            "example": "received event XXXXXXXXXXXX with id at 2024-08-08T12:58:22Z and started process with businessKey 4c7170ed-3518-41ee-8582-39ab65b00107",
            "type": "string"
          }
        },
        "required": [
          "businessKey",
          "message"
        ],
        "type": "object"
      },
      "kategorie": {
        "description": "Qualifier aus dem Beginn der EDIFact Nachricht / BGM",
        "type": "string"
      },
      "positionsnummer": {
        "description": "Positionsnummer",
        "type": "integer"
      },
      "preisNetzbetreiberCodenummer": {
        "description": "Preise des Netzbetreibers",
        "type": "string"
      },
      "rollencodenummer": {
        "description": "Gibt die Codenummer der Marktrolle an.",
        "type": "string"
      },
      "sparte": {
        "$ref": "#/components/schemas/Sparte",
        "description": "Enthält Informationen über die Sparte"
      },
      "staffelgrenzeBis": {
        "description": "staffelgrenzeBis",
        "format": "float",
        "type": "number"
      },
      "staffelgrenzeVon": {
        "description": "staffelgrenzeVon",
        "format": "float",
        "type": "number"
      },
      "startdatum": {
        "description": "startdatum",
        "format": "date-time",
        "type": "string"
      },
      "zeitbasis": {
        "$ref": "#/components/schemas/Zeiteinheit",
        "description": "Die Zeit(dauer) auf die sich der Preis bezieht. Z.B. ein Jahr für einen Leistungspreis der in €/kW/Jahr\nausgegeben wird."
      }
    }
  }
}