Restcomm-Connect icon indicating copy to clipboard operation
Restcomm-Connect copied to clipboard

New Organization domainName not set as expected and as explained in API doc

Open SlackingVeteran opened this issue 7 years ago • 4 comments

Process of adding new domainName in Organization as explained in RC API documentation says to add domainName test simply post http request with curl -X PUT "https://<accountSid>:<authtoke>@mycompany.restcomm.com/restcomm/2012-04-24/Organizations/test" which if success will return following output:

<Organization>
  <Sid>OR905d1b4e9d3045acb268f8d0fdf259ac</Sid>
  <DomainName>test.restcomm.com.</DomainName>
  <Status>active</Status>
  <DateCreated>Thu, 28 Sep 2017 16:11:39 +0000</DateCreated>
  <DateUpdated>Thu, 28 Sep 2017 16:11:39 +0000</DateUpdated>
</Organization>

As you can see in above output final domain name is test.restcomm.com..

Now I have been trying to achieve the same with my restcomm installation and trying to add new domainName abc and I was expecting it to result with abc.xyz.com, xyz.com being my original domain name but I get following in response in return:

<RestcommResponse>
  <Organization>
    <Sid>OR4fead74383624115b1e1aefd06d7248e</Sid>
    <DomainName>abc</DomainName>
    <Status>active</Status>
    <DateCreated>Thu, 25 Jan 2018 11:55:47 +0000</DateCreated>
    <DateUpdated>Thu, 25 Jan 2018 11:55:47 +0000</DateUpdated>
  </Organization>

Sadly that did not work same as in documentation. So I thought I will provide full domainName and replaced abc with abc.xyz.com in my HTTP post request because that was the final result I wanted to see. Now with full domainName this was the response I received from RC API:

Total Length of domain_name can be upto 255 Characters. It can contain only letters, number and hyphen - sign.. Please, choose a valid name and try again.

I am assuming it to be some sort of bug in the API or was it expected not to add full domainName? What could I do to achieve what I am trying to do?

SlackingVeteran avatar Jan 26 '18 06:01 SlackingVeteran

Thanks for raising this @suyashbhatt !

@maria-farooq does this sound familiar ? Any thoughts you can share on this? We can then hopefully improve the docs to avoid further confusion.

gsaslis avatar Feb 05 '18 16:02 gsaslis

Hi @suyashbhatt , Sorry about late response. As explained in API Documentation

Api is mainly responsible for communicating with configureable DNS hosting service provider (for example Route-53 or others) for making changes in record sets.

Can you share if you have configured a DNS provider in your deployment? Please check this https://www.restcomm.com/docs/connect/configuration/dns/dns-provisioning.html

maria-farooq avatar Mar 06 '18 08:03 maria-farooq

Hi @maria-farooq, i do not have dns provider configured in my setup. The documentation was for Aws Route 53 and I had no idea how to set it up for digitalocean dns provider.

SlackingVeteran avatar Mar 06 '18 14:03 SlackingVeteran

Hi @suyashbhatt , document also specifies that as part of initial configuration a developer can provide customer Class for any DNS server as long as it implements org.restcomm.connect.dns.DnsProvisioningManager. and after that developer can use this class to make API calls to DNS provider. This class can be configured as described in initial part of the documentation

maria-farooq avatar Mar 07 '18 06:03 maria-farooq