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

# Post Admin

> Save the admin document. The managed values cannot be written here.



## OpenAPI

````yaml https://app.podero.com/api/partners/v2.0/openapi.json post /api/partners/v2.0/org/{org_id}/admin
openapi: 3.1.0
info:
  title: Podero Partner API
  version: '2.0'
  description: >-
    This API provides a unified interaction point for Podero's partner
    companies.


    The goal of this API is to give partners easily integratable endpoints that
    don't require extensive software

    development. For this reason, the endpoints focus around user and device
    management, setting of preferences

    and high level device controls.


    While direct control of devices is implemented for special use cases such as
    pause power, we abstract away low level

    direct device steering so developers and partners can focus on delivering
    maximum value to end users.


    ## Authentication


    Send an OAuth2 access token in the `Authorization: Bearer <access_token>`
    header of each request.

    A token request must have a JSON body. The token endpoints do not read a
    form-encoded body.


    Server-to-server integrations use the client credentials grant:


    ```http

    POST /oauth2/token/

    Authorization: Basic base64(<client_id>:<client_secret>)

    Content-Type: application/json


    {"grant_type": "client_credentials"}

    ```


    The response does not contain a refresh token. The access token expires
    after `expires_in` seconds (one hour).

    To renew it, send the same request again. Use one token for all requests
    until shortly before it expires.

    Do not request a new token for each request. If a request returns `401`, get
    one new token and send the request

    again once. If it returns `401` again, the token is valid but the
    application has no access to that resource,

    and a new token does not change that.


    Apps where a person signs in use the password grant at `POST
    /api/partners/v2.0/auth/token`, and renew the

    session with the `refresh_token` grant at the same endpoint.
  termsOfService: https://www.podero.com/terms-and-conditions
servers: []
security: []
paths:
  /api/partners/v2.0/org/{org_id}/admin:
    post:
      tags:
        - Organization Configuration
      summary: Post Admin
      description: Save the admin document. The managed values cannot be written here.
      operationId: >-
        integrations_api_api_v2_organizations_configuration_organization_admin_router_post_admin
      parameters:
        - in: path
          name: org_id
          schema:
            format: uuid
            title: Org Id
            type: string
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AdminInput'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AdminOutput'
      security:
        - OAuth2: []
components:
  schemas:
    AdminInput:
      additionalProperties: false
      properties:
        revision:
          anyOf:
            - maxLength: 64
              type: string
            - type: 'null'
          title: Revision
        settings:
          $ref: '#/components/schemas/AdminValues'
      required:
        - revision
        - settings
      title: AdminInput
      type: object
    AdminOutput:
      properties:
        revision:
          title: Revision
          type: string
        settings:
          $ref: '#/components/schemas/AdminValuesOutput'
        readonly:
          $ref: '#/components/schemas/AdminReadonly'
        options:
          $ref: '#/components/schemas/OrganizationOptions'
      required:
        - revision
        - settings
        - readonly
        - options
      title: AdminOutput
      type: object
    AdminValues:
      additionalProperties: false
      properties:
        name:
          maxLength: 255
          minLength: 1
          title: Name
          type: string
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        contact:
          anyOf:
            - maxLength: 255
              type: string
            - type: 'null'
          title: Contact
        default_currency:
          default: EUR
          title: Default Currency
          type: string
        country:
          default: AT
          title: Country
          type: string
        trading_enabled:
          default: false
          title: Trading Enabled
          type: boolean
        optimization_basis:
          default: market
          title: Optimization Basis
          type: string
        audit_log_enabled:
          default: false
          title: Audit Log Enabled
          type: boolean
        text_overrides:
          additionalProperties: true
          title: Text Overrides
          type: object
      required:
        - name
        - text_overrides
      title: AdminValues
      type: object
    AdminValuesOutput:
      properties:
        name:
          title: Name
          type: string
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        contact:
          anyOf:
            - type: string
            - type: 'null'
          title: Contact
        default_currency:
          title: Default Currency
          type: string
        country:
          title: Country
          type: string
        trading_enabled:
          title: Trading Enabled
          type: boolean
        optimization_basis:
          title: Optimization Basis
          type: string
        audit_log_enabled:
          title: Audit Log Enabled
          type: boolean
        text_overrides:
          additionalProperties: true
          title: Text Overrides
          type: object
      required:
        - name
        - description
        - contact
        - default_currency
        - country
        - trading_enabled
        - optimization_basis
        - audit_log_enabled
        - text_overrides
      title: AdminValuesOutput
      type: object
    AdminReadonly:
      properties:
        organization_id:
          title: Organization Id
          type: string
        enabled_views:
          items:
            type: string
          title: Enabled Views
          type: array
        invite_enabled:
          title: Invite Enabled
          type: boolean
        included_device_brands:
          items:
            $ref: '#/components/schemas/Choice'
          title: Included Device Brands
          type: array
        unavailable_device_brands:
          items:
            $ref: '#/components/schemas/Choice'
          title: Unavailable Device Brands
          type: array
      required:
        - organization_id
        - enabled_views
        - invite_enabled
        - included_device_brands
        - unavailable_device_brands
      title: AdminReadonly
      type: object
    OrganizationOptions:
      properties:
        countries:
          items:
            $ref: '#/components/schemas/Choice'
          title: Countries
          type: array
        currencies:
          items:
            $ref: '#/components/schemas/Choice'
          title: Currencies
          type: array
        optimization_bases:
          items:
            $ref: '#/components/schemas/Choice'
          title: Optimization Bases
          type: array
        price_zones:
          items:
            $ref: '#/components/schemas/Choice'
          title: Price Zones
          type: array
      required:
        - countries
        - currencies
        - optimization_bases
        - price_zones
      title: OrganizationOptions
      type: object
    Choice:
      properties:
        id:
          title: Id
          type: string
        label:
          title: Label
          type: string
      required:
        - id
        - label
      title: Choice
      type: object
  securitySchemes:
    OAuth2:
      type: oauth2
      flows:
        password:
          tokenUrl: /api/partners/v2.0/auth/token
          scopes: {}
        clientCredentials:
          tokenUrl: /oauth2/token/
          scopes: {}

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.