Table of Contents

Get Project Listing

This API is used to get listing of all projects.

  • API Route:
    • https://api.enablex.io/cpaas/projects
    • https://api.enablex.io/cpaas/projects?page={{$PAGE_NUM}}
  • HTTP Request: GET
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Response Example:

{
  "result": 1,
  "search": {
    "page": "Number",
    "page_length": "Number",
    "customer_id": "String",
    "search_by": "String",
    "search_string": "String",
    "order_by": "String",
    "order_qualify": "String"
  },
  "projects": [
    {
      "customer_id": "String",
      "customer_name": "String",
      "app_id": "String",
      "app_key": "String",
      "app_name": "String",
      "category_id": "String",
      "category_name": "String",
      "short_desc": "String",
      "description": "String",
      "services_incl": {
        "video": "Boolean",
        "sms": "Boolean",
        "voice": "Boolean"
      },
      "status": "String",
      "status_ex": "String",
      "created_at": "Date",
      "updated_at": "Date",
      "suspended_at": "Date"
    }
  ]
}

Response Explanation (Only for important Object and Keys) :

Object/KeyDescription
app_idUnique App ID. This is used in API Call as username.
app_keyApp Key. This is used in API Call as password.
app_nameTo search CDR for a customer.
category_idCategory/Classification ID – Refer related data-pool api.
category_nameName of category.
services_inclObject. This shows what all services are included in this project.

Error Codes

Code Description
1101Invalid page. Number. Range: 1+.
1102Invalid page_num. Number. Range: 1+.
1105Invalid order_qualify. Enumerated Data: asc, desc.

Get Project Information

This API is used to get Information for a given Project’s App-ID. 

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}
  • HTTP Request: GET
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Response Example:

{
  "result": 1,
  "project": {
    "customer_id": "String",
    "customer_name": "String",
    "app_id": "String",
    "app_key": "String",
    "app_name": "String",
    "category_id": "String",
    "category_name": "String",
    "short_desc": "String",
    "description": "String",
    "services_incl": {
      "video": "Boolean",
      "sms": "Boolean",
      "voice": "Boolean"
    },
    "video": {
      "notification_url": "String",
      "media_zone": [
        "String"
      ],
      "sip": {
        "server_url": "String",
        "username": "String",
        "password": "String",
        "sig_servers": [
          "String"
        ],
        "media_servers": [
          "String"
        ]
      },
      "phone": [
        {
          "in": "Boolean",
          "out": "Boolean",
          "country": "String",
          "country_code": "String",
          "phone": "String",
          "toll": "Boolean"
        }
      ],
      "recording": {
        "files": {
          "record_individual": "Boolean",
          "record_transcoded": "Boolean",
          "meta": "Boolean",
          "transcription": "Boolean",
          "text_chat": "Boolean",
          "delete": "Boolean"
        },
        "watermark": {
          "enabled": "Boolean",
          "img_path": {
            "IN": "IN image path",
            "DE": "DE image path",
            "US": "US image path",
            "SG": "SG image path"
          },
          "opacity": "Number",
          "align": {
            "horz": "String",
            "vert": "String",
            "offset_x": "Number",
            "offset_y": "Number"
          }
        }
      },
      "recording_delivery": {
        "ftp": {
          "opted": "Boolean",
          "periodicity": "String",
          "periodicity_ex": "String",
          "protocol": "String",
          "encryption": "String",
          "host": "String",
          "port": "Integer",
          "username": "String",
          "password": "String",
          "path": "String"
        },
        "scp": {
          "opted": "Boolean",
          "periodicity": "String",
          "periodicity_ex": "String",
          "host": "String",
          "port": "Integer",
          "username": "String",
          "password": "String",
          "path": "String"
        }
      }
    },
    "sms": {
      "incoming": "Boolean",
      "outgoing": "Boolean",
      "default": {
        "sender_name": "String",
        "long_code": "String",
        "short_code": "String",
        "keyword": "String",
        "in_webhook": {
          "url": "String",
          "auth": "Boolean",
          "username": "String",
          "password": "String"
        },
        "delivery_webhook": {
          "url": "String",
          "auth": "Boolean",
          "username": "String",
          "password": "String"
        }
      }
    },
    "voice": {
      "in": "Boolean",
      "out": "Boolean",
      "sip": {
        "server_url": "String",
        "username": "String",
        "password": "String",
        "sig_servers": [
          "String"
        ],
        "media_servers": [
          "String"
        ]
      },
      "inbound": {
        "event_url": "String",
        "welcome_text": "String",
        "voice_type": "String",
        "language": "String",
        "auto_record": "Boolean"
      },
      "notification_url": "String"
    },
    "status": "String",
    "status_ex": "String",
    "created_at": "Date",
    "updated_at": "Date",
    "suspended_at": "Date"
  }
}

Response Explanation (Only for important Object and Keys) :

Object/KeyDescription
app_idUnique App ID. This is used in API Call as username.
app_keyApp Key. This is used in API Call as password.
app_nameTo search CDR for a customer.
category_idCategory/Classification ID – Refer related data-pool api.
services_inclObject. This shows what all services are included in this project.
videoObject. It contains all settings information of Video Service for this Project.
video.notification_urlWebhook Notification URL.
video.media_zoneAll the media-zones opted for Video Session hosting.
video.sipSIP integration with Video Service / host information.
video.phoneTelephone integration with Video Server / phone infomration.
video.recordingObject. It contains information different aspect of recording.
video.recording.filesObject. It contains information on what all type of files you look to be delivered. And, if files to be deleted after delivery.
video.recording.watermarkObject. It contains information on watermarking on recording.
video.recording.deliveryArray of Objects. IT contains delivery method and related access information of your server for recording delivery.
smsObject. It contains all settings information of SMS Service for this Project.
sms.incomingIf incoming sms is enabled.
sms.outgoingIf outgoing sms is enabled.
sms.defaultObject. Contains information on default SMS Service Settings.
voiceObject. It contains all settings information of Voice Service for this Project.
voice.inIf incoming voice call is enabled.
voice.outIf outgoing voice call is enabled.
voice.notification_urlWebhook URL for notification post.
voice.sipSIP Integration with Voice Service. SIP Host information.

Error Codes

Code Description
1007Invalid App ID.

Add Project

This API is used to add new project  against a Customer. 

  • API Route: https://api.enablex.io/cpaas/projects
  • HTTP Request: POST
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "customer_id": "String",
  "app_name": "String",
  "category_id": "String",
  "short_desc": "String",
  "description": "String"
}

Request Explanation:

Object/KeyDescription
customer_idString. Optional. If given, project will be created under the given customer-id.
app_nameString. Required. To search CDR for a customer.
category_idString. Required. Category/Classification ID – Refer related data-pool api.
services_inclObject. Required. This shows what all services are included in this project.

Response Example:

{
  "result": 1,
  "project": {
    "app_id": "String",
    "app_key": "String",
    "app_name": "String"
  }
}

Response Explanation :

Object/KeyDescription
projectNew project Object containing key information to save in database for references, usage in API queries etc.
app_idUnique ID for App. Used in API Call as username for http authentication.
app_keyApp Key. Used in API Call as password for http authentication.

Error Codes

Code Description
1008Invalid Category ID.
1009 Services.incl not given. At least one service must be included.

Edit Project

This API is used to update project Information. All Keys in JSON payload are optional. Use only the one which you want to edit. 

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}
  • HTTP Request: POST
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "app_name": "String",
  "category_id": "String",
  "short_desc": "String",
  "description": "String",
  "status": "String"
}

Request Explanation:

Object/KeyDescription
app_nameString. Required. To search CDR for a customer.
category_idString. Required. Category/Classification ID – Refer related data-pool api.
services_inclObject. Required. This shows what all services are included in this project.

Response Example:

{
  "result": 1,
  "msg": "Project $app_name has been updated",
  "user": {
    "app_id": "String",
    "app_name": "Sting"
  }
}

Response Explanation :

Object/KeyDescription
projectNew project Object containing key information to save in database for references, usage in API queries etc.
app_idUnique ID for App. Used in API Call as username for http authentication.
app_keyApp Key. Used in API Call as password for http authentication.

Error Codes

Code Description
1007Invalid App ID.

Reset API Access Key

This API is used to reset API Access Key for a Project.

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}/reset_key
  • HTTP Request: POST
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Response Example:

{
  "result": 1,
  "msg": "API Access Key for Project $app_name has been reset",
  "project": {
    "app_id": "String",
    "app_key": "String",
    "app_name": "Sting"
  }
}

Response Explanation :

Object/KeyDescription
app_keyApp Key. Used in API Call as password for http authentication.

Error Codes

Code Description
1007Invalid App ID.

Configure Video in Project

This API is used to configure Video Service in the Project. All Keys in JSON payload are optional. Use only the one which you want to edit.

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}/video
  • HTTP Request: PATCH
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "notification_url": "String",
  "sip": {
    "server_url": "String",
    "username": "String",
    "password": "String",
    "sig_servers": [
      "String"
    ],
    "media_servers": [
      "String"
    ]
  },
  "phone": [
    {
      "in": "Boolean",
      "out": "Boolean",
      "country": "String",
      "country_code": "String",
      "phone": "string"
    }
  ],
  "encryption": {
    "encryption_key": "String"
  },
  "recording": {
    "files": {
      "record_individual": "Boolean",
      "record_transcoded": "Boolean",
      "meta": "Boolean",
      "transcription": "Boolean",
      "text_chat": "Boolean",
      "delete": "Boolean"
    },
    "watermark": {
      "enabled": "Boolean",
      "img_path": {
        "IN": "IN image path",
        "DE": "DE image path",
        "US": "US image path",
        "SG": "SG image path"
      },
      "opacity": "Number",
      "align": {
        "horz": "String",
        "vert": "String",
        "offset_x": "Number",
        "offset_y": "Number"
      }
    },
    "delivery": {
      "ftp": {
        "opted": "Boolean",
        "periodicity": "String",
        "periodicity_ex": "String",
        "protocol": "String",
        "encryption": "String",
        "host": "String",
        "port": "Integer",
        "username": "String",
        "password": "String",
        "path": "String"
      },
      "scp": {
        "opted": "Boolean",
        "periodicity": "String",
        "host": "String",
        "port": "Integer",
        "username": "String",
        "password": "String",
        "path": "String"
      },
      "s3": {
        "opted": "boolean",
        "mode": "secret_access_based",
        "access_key_id": "String",
        "secret_key": " String ",
        "path": " String ",
        "region": "us-east-1",
        "env_auth": "boolean"
      },
      "gdrive": {
        "opted": "true",
        "root_folder_id": "String",
        "path": "String",
        "access_file": "File-JSON"
      },
      "azure": {
        "storage_account": "String",
        "access_key": "String",
        "dest_path": "String"
      }
    }
  }
}

Request Explanation:

Object/KeyDescription
customer_idString. Optional. If given, project will be created under the given customer-id.
app_nameString. Required. To search CDR for a customer.
category_idString. Required. Category/Classification ID – Refer related data-pool api.
services_inclObject. Required. This shows what all services are included in this project.

Response Example:

{
  "result": 1,
  "msg": "Project $app_name has been updated with Video Service Setting",
  "user": {
    "app_id": "String",
    "app_name": "Sting"
  }
}

Response Explanation :

Object/KeyDescription
app_idUnique ID for App. Used in API Call as username for http authentication.
app_nameName of the application/project.

Error Codes

Code Description
1007Invalid App ID.

Configure Voice in Project

This API is used to configure Voice Service in the Project. All Keys in JSON payload are optional. Use only the one which you want to edit.

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}/voice
  • HTTP Request: PATCH
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "in": "Boolean",
  "out": "Boolean",
  "sip": {
    "server_url": "String",
    "username": "String",
    "password": "String",
    "sig_servers": [
      "String"
    ],
    "media_servers": [
      "String"
    ]
  },
  "inbound": {
    "event_url": "String",
    "welcome_text": "String",
    "voice_type": "String",
    "language": "String",
    "auto_record": "Boolean"
  },
  "phone": [
    {
      "in": "Boolean",
      "out": "Boolean",
      "country": "String",
      "country_code": "String",
      "phone": "string"
    }
  ],
  "notification_url": "String"
}

Response Example:

{
  "result": 1,
  "msg": "Project $app_name has been updated with Video Service Setting",
  "user": {
    "app_id": "String",
    "app_name": "Sting"
  }
}

Response Explanation :

Object/KeyDescription
app_idUnique ID for App. Used in API Call as username for http authentication.
app_nameName of the application/project.

Error Codes

Code Description
1007Invalid App ID.

Configure SMS in Project

This API is used to configure SMS Service in the Project. All Keys in JSON payload are optional. Use only the one which you want to edit.

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}/sms
  • HTTP Request: PATCH
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "incoming": "Boolean",
  "outgoing": "Boolean",
  "default": {
    "sender_name": "String",
    "long_code": "String",
    "short_code": "String",
    "keyword": "String",
    "in_webhook": {
      "url": "String",
      "auth": "Boolean",
      "username": "String",
      "password": "String"
    },
    "delivery_webhook": {
      "url": "String",
      "auth": "Boolean",
      "username": "String",
      "password": "String"
    }
  }
}

Response Example:

{
  "result": 1,
  "msg": "Project $app_name has been updated with SMS Service Setting",
  "user": {
    "app_id": "String",
    "app_name": "String"
  }
}

Response Explanation :

Object/KeyDescription
app_idUnique ID for App. Used in API Call as username for http authentication.
app_nameName of the application/project.

Error Codes

Code Description
1007Invalid App ID.

Configure Video Embed in Project

This API is used to configure Video Embed in a Video Project in the Project. All Keys in JSON payload are optional. Use only the one which you want to edit.

  • API Route: https://api.enablex.io/cpaas/projects/{{$APP_ID}}/video-embed
  • HTTP Request: PATCH
  • Access Mechanism: HTTP Basic Authentication
  • Role Based Accessibility: All
    • Admin (Gets projects against any customer)
    • Customer (Gets own projects )

Headers Explanation:

  • Content-Type: To have application/json to notify that the body content is in JSON.
  • Authorization: To have Token Access Information.

Request Example:

{
  "subdomain": "bbbbb",
  "embed_template_id": "String",
  "access_mode": {
    "iframe": {
      "enabled": true,
      "iframing_hosts": []
    }
  },
  "exit_url": "String",
  "options": {
    "recording": false,
    "invite": false,
    "breakout_room": true,
    "sidebar_call": false,
    "poll": false,
    "outbound_call": false,
    "room_mode_switch": true,
    "player_mode_switch": {
      "player": false,
      "global": false,
      "default": "cover"
    },
    "grid_mode_switch": {
      "gallery": true,
      "leader": true,
      "default": "leader"
    },
    "co_browsing": {
      "show": false
    },
    "deviceSetting": true,
    "lock_room": true,
    "fixed_toolbar": false,
    "room_name": true,
    "screenshare": {
      "show": true,
      "for_moderator": true,
      "for_participants": true,
      "moderated": false
    },
    "live_streaming": true,
    "floor_control": true,
    "emoji": true,
    "file_sharing": true,
    "bg_replace": {
      "show": true,
      "bg_blur": true
    },
    "user_list": {
      "to_moderators": {
        "show": true,
        "moderators": true,
        "participants": true
      },
      "to_participants": {
        "show": true,
        "moderators": true,
        "participants": true
      },
      "to_participants_wb": {
        "show": false,
        "moderators": false,
        "participants": false
      }
    },
    "user_count": {
      "to_moderators": {
        "show": true,
        "moderators": true,
        "participants": true
      },
      "to_participants": {
        "show": true,
        "moderators": true,
        "participants": true
      }
    },
    "group_chat": true,
    "lobby": {
      "show": false,
      "wait_timeout": "120"
    },
    "pvt_chat": {
      "show": true,
      "to_moderator": true,
      "to_participants": true
    },
    "whiteboard": {
      "show": true
    },
    "toolbar_setup": {
      "screenshare": {
        "enabled": true,
        "kebab": false
      },
      "whiteboard": {
        "enabled": true,
        "kebab": false
      },
      "livestream": {
        "enabled": true,
        "kebab": false
      },
      "floorControl": {
        "enabled": true,
        "kebab": true
      },
      "lobby": {
        "enabled": false,
        "kebab": false
      },
      "breakoutRoom": {
        "enabled": true,
        "kebab": true
      },
      "lockRoom": {
        "enabled": true,
        "kebab": true
      },
      "backgroundReplacement": {
        "enabled": true,
        "kebab": true
      },
      "chat": {
        "enabled": true,
        "kebab": false
      },
      "recording": {
        "enabled": false,
        "kebab": false
      },
      "annotation": {
        "enabled": false,
        "kebab": false
      }
    },
    "user_line_info": {
      "username": true,
      "cam": true,
      "mic": true,
      "bw": true
    },
    "disconnect": {
      "show": true,
      "exit_url": "",
      "target": "_blank",
      "bg_color": ""
    },
    "toolbar": {
      "draggable": true,
      "fixed": false
    },
    "audio_mute": false,
    "video_mute": false,
    "mute_all": true,
    "clock": true,
    "full_screen": true,
    "room_size": "50",
    "video_grid": "12",
    "icon_bg_opacity": "0.2",
    "left_pane_color": "#FFF",
    "update_settings": "update",
    "exit_url": "",
    "line_icon_color": "#1E1E1C",
    "icon_type": "line",
    "solid_icon_color": "",
    "background_color": "#3D676F",
    "toolbar_color": "#FFFEFF",
    "font": {
      "room_name_text_size": "14",
      "top_bar_text_size": "14",
      "chat_text_size": "14",
      "family": "Garamond"
    },
    "user_exit": {
      "moderator": true,
      "participant": false,
      "track": ""
    },
    "record_start": {
      "moderator": true,
      "participant": false,
      "track": ""
    },
    "record_stop": {
      "moderator": true,
      "participant": false,
      "track": ""
    },
    "session_expiry": {
      "moderator": true,
      "track": ""
    },
    "user_in_lobby": {
      "moderator": true,
      "track": ""
    },
    "chat_in": {
      "all": true,
      "track": ""
    }
  },
  "video_background_color": "#323548"
}

Response Example:

{
  "result": 1,
  "msg": "Project $app_name has been updated with Video Embed Setting",
  "project": {
    "app_id": "String",
    "app_name": "String"
  },
  "room": {
    "room_id": "6246efa1196ea481db234227",
    "participant_meeting_url": "https://kajalbyadminnew.yourvideo.tech/6246efa1196ea481db234227",
    "host_meeting_url": "https://kajalbyadminnew.yourvideo.tech/host/NjI0NmVmYTExOTZlYTQ4MWRiMjM0MjI3LTYyNDZlZjQzYWJlMzZiMzNlMjc1OWE0Mg==",
    "participant_iframe_embed": "<iframe \n allow=\"camera; microphone; fullscreen; speaker; display-capture\"\nsrc=\"https://kajalbyadminnew.yourvideo.tech/6246efa1196ea481db234227\">\n</iframe>",
    "moderator_iframe_embed": "<iframe \n allow=\"camera;  microphone; fullscreen; speaker; display-capture\"\nsrc=\"https://kajalbyadminnew.yourvideo.tech/host/NjI0NmVmYTExOTZlYTQ4MWRiMjM0MjI3LTYyNDZlZjQzYWJlMzZiMzNlMjc1OWE0Mg==\" >\n</iframe>"
  }
}

Error Codes

Code Description
1007Invalid App ID.
1110Invalid Sub-Domain.
1111Sub-Domain name already in use.