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

# Authenticate account token

> Authenticates an account using a client ID and secret, for server-to-server (machine-to-machine) integrations that authenticate as an account rather than a user. Contact support@realtimelca.com to obtain a client ID and secret for your account. The response returns an access token that must be supplied as `Authorization: Bearer <access_token>` on every other endpoint.



## OpenAPI

````yaml /api-reference/realtime-lca-openapi.yaml post /api-token
openapi: 3.0.0
info:
  title: Real-Time LCA REST Documentation
  version: 1.0.0
  description: >-
    ### Description 📝


    This collection contains a set of REST API requests for the Real-Time LCA
    (Life Cycle Assessment) service.


    ### Authenticate user 👤🔑


    In the `Auth` folder there's a `POST` request for authenticating the user.


    In this request body you can type in the user RTLCA user credentials
    (username & password) and a succesfull (`200 OK`) response will set the
    collection `BearerToken` variable which is then inherited by all other
    requests.
servers:
  - url: https://api.realtimelca.com/rest/api
    description: REST API.
  - url: https://api.realtimelca.com/epd/api
    description: EPD API.
  - url: https://auth.realtimelca.com/frontegg/identity/resources/auth/v1
    description: Authentication API (Frontegg identity v1).
  - url: https://realtimelca-prod.hasura.app
    description: GraphQL API (Hasura).
security:
  - BearerAuth: []
tags:
  - name: Auth
  - name: User
  - name: Overview
  - name: Project
  - name: Dashboard
  - name: Mapping
  - name: Automapping
  - name: Transport
  - name: Waste
  - name: Inspect
  - name: Report
  - name: Images
  - name: Library
  - name: Datasource
  - name: Owner
  - name: Material
  - name: Constructions
  - name: Enums
paths:
  /api-token:
    servers:
      - url: https://auth.realtimelca.com/frontegg/identity/resources/auth/v2
    post:
      tags:
        - Auth
      summary: Authenticate account token
      description: >-
        Authenticates an account using a client ID and secret, for
        server-to-server (machine-to-machine) integrations that authenticate as
        an account rather than a user. Contact support@realtimelca.com to obtain
        a client ID and secret for your account. The response returns an access
        token that must be supplied as `Authorization: Bearer <access_token>` on
        every other endpoint.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                clientId:
                  type: string
                secret:
                  type: string
            example:
              clientId: ''
              secret: ''
      responses:
        '200':
          description: The account was authenticated and an access token was issued.
          content:
            application/json:
              schema:
                type: object
                properties:
                  access_token:
                    type: string
                  refresh_token:
                    type: string
                  expires_in:
                    type: integer
                    description: Access token lifetime, in seconds.
                  expires:
                    type: string
                    description: Access token expiry, as an HTTP date.
              example:
                access_token: ''
                refresh_token: ''
                expires_in: 86400
                expires: ''
      security: []
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````