code: public static base_response add(nitro_service client, dnscnamerec resource) throws Exception {
  		dnscnamerec addresource = new dnscnamerec();
  		addresource.aliasname = resource.aliasname;
  		addresource.canonicalname = resource.canonicalname;
  		addresource.ttl = resource.ttl;
  		return addresource.add_resource(client);
  	}
docs: Use this API to add dnscnamerec.