> ## Documentation Index
> Fetch the complete documentation index at: https://docs.axle.energy/llms.txt
> Use this file to discover all available pages before exploring further.

# Send tariff

> Send notification of a tariff update for an asset.

The `off_peak_times` field must comply with the OSM opening hours standard (https://wiki.openstreetmap.org/wiki/Key:opening_hours) and have a valid timezone, or a 400 error will be returned.

The same off-peak times apply every day, day-of-week selectors are not supported. Use `,` to separate multiple time ranges. Common examples:
- Same-day off-peak (e.g. midnight to 7am): `00:00-07:00`
- Overnight off-peak (e.g. 11:30pm to 5:30am): `00:00-05:30, 23:30-24:00`



## OpenAPI

````yaml POST /entities/asset/{asset_id}/event/tariff-update
openapi: 3.1.0
info:
  title: Axle API Docs
  description: >-
    For full documentation please see our official docs at <a
    href='http://docs.axle.energy'>docs.axle.energy</a>
  version: 1.4.6
servers:
  - url: https://api-sandbox.axle.energy
security: []
tags:
  - name: 1. Authentication
    description: Authenticate yourself with the Axle API
  - name: 2. Meters
    description: Find key info about your sites
  - name: 3. Sites
    description: Register your sites with Axle; configure market participation
  - name: 4. Assets
    description: Register your assets with Axle
  - name: 5. Data
    description: Send asset metrics to Axle, for analysis and optimisation purposes
  - name: 6. Rewards
    description: >-
      Determine how much your users have earned by participating with Axle;
      allow balance withdrawal
  - name: 7. Validation
    description: Validate structured data against Axle's rules
  - name: 8. Examples
    description: Get example data for testing
paths:
  /entities/asset/{asset_id}/event/tariff-update:
    post:
      tags:
        - 4. Assets
      summary: Asset Tariff Update Event
      description: >-
        Send notification of a tariff update for an asset.


        The `off_peak_times` field must comply with the OSM opening hours
        standard (https://wiki.openstreetmap.org/wiki/Key:opening_hours) and
        have a valid timezone, or a 400 error will be returned.


        The same off-peak times apply every day, day-of-week selectors are not
        supported. Use `,` to separate multiple time ranges. Common examples:

        - Same-day off-peak (e.g. midnight to 7am): `00:00-07:00`

        - Overnight off-peak (e.g. 11:30pm to 5:30am): `00:00-05:30,
        23:30-24:00`
      operationId: >-
        asset_tariff_update_event_entities_asset__asset_id__event_tariff_update_post
      parameters:
        - required: true
          schema:
            type: string
            format: uuid
            title: Asset Id
          name: asset_id
          in: path
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TariffUpdateEventRequest'
        required: true
      responses:
        '200':
          description: Tariff update event successfully processed
          content:
            application/json:
              schema: {}
        '400':
          description: Invalid tariff format or timezone
        '404':
          description: Asset not found or not authorized to access
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '500':
          description: Server error while processing event
      security:
        - OAuth2PasswordBearer: []
components:
  schemas:
    TariffUpdateEventRequest:
      properties:
        tariff:
          allOf:
            - $ref: '#/components/schemas/Tariff'
          title: Tariff
          description: Updated tariff information.
      type: object
      required:
        - tariff
      title: TariffUpdateEventRequest
      description: Request model for a user's tariff update.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    Tariff:
      properties:
        off_peak_times:
          type: string
          title: Off Peak Times
        timezone:
          type: string
          title: Timezone
        tariff_type:
          $ref: '#/components/schemas/TariffType'
      type: object
      required:
        - off_peak_times
        - timezone
      title: Tariff
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    TariffType:
      type: string
      enum:
        - single_rate
        - dual_rate
        - dynamic
        - smart
        - unknown
      title: TariffType
      description: An enumeration.
  securitySchemes:
    OAuth2PasswordBearer:
      type: oauth2
      flows:
        password:
          scopes: {}
          tokenUrl: auth/token-form

````