openapi: 3.1.0
info:
  title: Registration as a Service V3 APIs
  description: >-
    Registration As A Service (RaaS) is an end-to-end user management platform.
    RaaS offers a comprehensive cloud-based user registration system that
    supports social login, allowing sites to maintain a unified user database
    for both social and traditional sites.

    Login credentials are a necessary component of customer loyalty and native
    identity services makes adding login easy. Add full registration as service
    to your site or enhance your site or enhance your existing registration
    process with social login or single sign-on. The User API is used to
    register and update information in the RaaS module.
  version: 3.0.1
servers:
  - url: https://s33.socialannex.com/api/v1.0/
paths:
  /forgotPassword:
    post:
      tags:
        - Users
      summary: Reset the password for a member
      description: >-
        This API is used to reset the password for a member if the member
        forgets their password. A reset password link will be sent to the email
        address that was provided to Annex Cloud upon their registration.
      operationId: forgotPassword
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                template_id:
                  description: >-
                    Enter the template ID, the template ID is generated for the
                    templates when they are created in RaaS.
                  example: 4304
                  type: integer
                user_id:
                  description: Enter the user ID of the member.
                  example: user@domain.com
                  type: string
              required:
                - template_id
                - user_id
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/forgotPassword'
            application/xml:
              schema:
                $ref: '#/components/schemas/forgotPassword'
        '400':
          description: AC2008 User ID invalid
  /register:
    post:
      tags:
        - Users
      summary: Register a member in the RaaS module
      description: This API is used for members to become registered in the RaaS module.
      operationId: register
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                template_id:
                  description: >-
                    This API is used for members to become registered in the
                    RaaS module.
                  example: 4304
                  type: integer
                user_id:
                  description: Enter the user ID of the member.
                  example: user@domain.com
                  type: string
                first_name:
                  description: Enter the first name of the member.
                  example: John
                  type: string
                last_name:
                  description: Enter the last name of the member.
                  example: Smith
                  type: string
                password:
                  description: >-
                    Enter the password, the password is used to login to the
                    RaaS module.
                  example: Test@123
                  type: string
                referral_code:
                  description: >-
                    Enter the unique code provided by the Refer-a-Friend program
                    (if applicable).
                  example: HTG078
                  type: string
                preferences:
                  description: >-
                    Enter the information regarding the fields that exist in
                    this object. The fields in the object vary as per the
                    client’s request. The following displayed three fields are
                    examples.
                  type: object
                  properties:
                    birth_date:
                      description: >-
                        Enter the DOB of the member, the format of the date is
                        “DD-MM-YEAR”.
                      example: 9-25-1992
                      type: string
                    phone_number:
                      description: Enter the phone number of the member.
                      example: 9856799999
                      type: integer
                    newsletter_enable:
                      description: >-
                        Enter YES if the newsletter needs to be enabled and
                        enter NO if the newsletter needs to be disabled.
                      example: 'YES'
                      type: string
              required:
                - template_id
                - user_id
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/register'
            application/xml:
              schema:
                $ref: '#/components/schemas/register'
        '400':
          description: >-
            AC2007 An account with that email address already exists. Please
            sign in. If you forgot your password, select Forgot Password and
            follow instructions. | AC2004 Email validation has failed.
  /editUser:
    post:
      tags:
        - Users
      summary: Edit the member's information in the RaaS module
      description: >-
        This API is used to edit the member's information that already exists in
        the RaaS database and to add new information that was not provided when
        the member was registered into the RaaS module.
      operationId: editUser
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                template_id:
                  description: >-
                    This API is used for members to become registered in the
                    RaaS module.
                  example: 4304
                  type: integer
                user_id:
                  description: Enter the user ID of the member.
                  example: user@domain.com
                  type: string
                first_name:
                  description: Enter the first name of the member.
                  example: John
                  type: string
                last_name:
                  description: Enter the last name of the member.
                  example: Smith
                  type: string
                referral_code:
                  description: >-
                    Enter the unique code provided by the Refer-a-Friend program
                    (if applicable).
                  example: HTG078
                  type: string
                preferences:
                  description: >-
                    Enter the information regarding the fields that exist in
                    this object. The fields in the object vary as per the
                    client’s request. The following displayed three fields are
                    examples.
                  type: object
                  properties:
                    birth_date:
                      description: >-
                        Enter the DOB of the member, the format of the date is
                        “DD-MM-YEAR”.
                      example: 9-25-1992
                      type: string
                    phone_number:
                      description: Enter the phone number of the member.
                      example: 9856799999
                      type: integer
                    newsletter_enable:
                      description: >-
                        Enter YES if the newsletter needs to be enabled and
                        enter NO if the newsletter needs to be disabled.
                      example: 'YES'
                      type: string
              required:
                - template_id
                - user_id
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/editUser'
            application/xml:
              schema:
                $ref: '#/components/schemas/editUser'
        '400':
          description: >-
            AC2007 An account with that email address already exists. Please
            sign in. If you forgot your password, select Forgot Password and
            follow instructions. | AC2004 Email validation has failed.
  /login:
    post:
      tags:
        - Users
      summary: Log in as a member in the RaaS module
      description: >-
        This API is used to login into the RaaS module for members by using
        their login credentials.
      operationId: login
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                template_id:
                  description: >-
                    Enter the template ID, the template ID is generated for the
                    templates when they are created in RaaS.
                  example: 4304
                  type: integer
                user_id:
                  description: Enter the user ID of the member.
                  example: user@domain.com
                  type: string
                password:
                  description: >-
                    Enter the password, the password created when the member
                    registered to the RaaS module.
                  example: Test@123
                  type: string
              required:
                - template_id
                - user_id
                - password
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/login'
            application/xml:
              schema:
                $ref: '#/components/schemas/login'
        '400':
          description: AC2014 Incorrect Password   | AC2008 User ID and Password invalid
components:
  schemas:
    forgotPassword:
      type: object
      properties:
        message:
          type: string
          description: >-
            Displays the message "A reset password link has been sent to your
            inbox".
          example: A reset password link has been sent to your inbox
    register:
      type: object
      properties:
        userData:
          type: object
          description: Displays the registered member details as shown below.
          properties:
            user_id:
              type: string
              description: >-
                Displays the unique identifier for the member. It is a unique
                numerical code assigned to each member who joined the RaaS
                program. The user ID is provided to the member by Annex Cloud.
              example: user@domain.com
            fname:
              type: string
              description: Displays the first name of the member.
              example: John
            lname:
              type: string
              description: Displays the last name of the member.
              example: Smith
            email:
              type: string
              description: Displays the email address of the member.
              example: mukesh1@gmail.com
            verify_status:
              type: integer
              description: >-
                Displays 1 if the member's email is verified and displays 0 if
                the member's email is not verified.
              example: 1
            db_add_date:
              type: string
              description: >-
                Displays the date when the member's information was added to the
                database (member registered date). The format of the date is
                “yyyy-MM-dd'T'HH:mm:ss Z”.
              example: 2020-10-30T05:30:00+0000
            birth_date:
              type: string
              description: >-
                Displays the DOB of the member in yyyy-MM-dd'T'HH:mm:ss Z
                format.
              example: 2020-10-30T05:30:00+0000
            phone_number:
              type: integer
              description: Displays the phone number of the member.
              example: 9856799999
            newsletter_enable:
              type: string
              description: >-
                Displays YES if the newsletter is enabled and displays NO if the
                newsletter is disabled.
              example: 'YES'
    editUser:
      type: object
      properties:
        user_id:
          type: string
          description: >-
            Displays the unique identifier for the member. It is a unique
            numerical code assigned to each member who joined the RaaS program.
            The user ID is provided to the member by Annex Cloud.
          example: user@domain.com
        fname:
          type: string
          description: Displays the first name of the member.
          example: John
        lname:
          type: string
          description: Displays the last name of the member.
          example: Smith
        email:
          type: string
          description: Displays the email address of the member.
          example: mukesh1@gmail.com
        verify_status:
          type: integer
          description: >-
            Displays 1 if the member's email is verified and displays 0 if the
            member's email is not verified.
          example: 1
        db_add_date:
          type: string
          description: >-
            Displays the date when the member's information was added to the
            database (member registered date). The format of the date is
            “yyyy-MM-dd'T'HH:mm:ss Z”.
          example: 2020-10-30T05:30:00+0000
    login:
      type: object
      properties:
        user_id:
          type: string
          description: >-
            Displays the unique identifier for the member. It is a unique
            numerical code assigned to each member who joined the RaaS program.
            The user ID is provided to the member by Annex Cloud.
          example: user@domain.com
        fname:
          type: string
          description: Displays the first name of the member.
          example: John
        lname:
          type: string
          description: Displays the last name of the member.
          example: Smith
        email:
          type: string
          description: Displays the email address of the member.
          example: mukesh1@gmail.com
        verify_status:
          type: integer
          description: >-
            Displays 1 if the member's email is verified and displays 0 if the
            member's email is not verified.
          example: 1
        db_add_date:
          type: string
          description: >-
            Displays the date when the member's information was added to the
            database (member registered date). The format of the date is
            “yyyy-MM-dd'T'HH:mm:ss Z”.
          example: 2020-10-30T05:30:00+0000
tags:
  - name: Users
    description: >-
      Registration as a Service (RaaS) is a concept where Annex Cloud provides
      registration and login functionalities to client sites.

      You can Create, Update, and Delete the Template in Registration as a
      Service (RaaS). Updated details are stored in the Registration as a
      Service (RaaS) database. Members must be registered in the RaaS database
      to modify member information.

      Our team is committed to providing excellent developer support, so if you
      encounter any challenges or have any questions, please don't hesitate to
      reach out to us. We want to ensure that your experience with the
      Registration as a Service (RaaS) API is seamless and successful.

      Login credentials are a necessary component of customer loyalty and native
      identity services make adding login easy. Add full registration as a
      service to your site or enhance your site or enhance your existing
      registration process with social login or single sign-on. User API
      provides information about the user from registering to the forgot
      password.
security:
  - MuseumPlaceholderAuth: []
