text
stringlengths
81
112k
Method to delete ipv6's by their ids :param ids: Identifiers of ipv6's :return: None def delete(self, ids): """ Method to delete ipv6's by their ids :param ids: Identifiers of ipv6's :return: None """ url = build_uri_with_ids('api/v3/ipv6/%s/', ids) ...
Method to update ipv6's :param ipv6s: List containing ipv6's desired to updated :return: None def update(self, ipv6s): """ Method to update ipv6's :param ipv6s: List containing ipv6's desired to updated :return: None """ data = {'ips': ipv6s} i...
Method to create ipv6's :param ipv6s: List containing vrf desired to be created on database :return: None def create(self, ipv6s): """ Method to create ipv6's :param ipv6s: List containing vrf desired to be created on database :return: None """ data = ...
Method to search ipv4's based on extends search. :param search: Dict containing QuerySets to find ipv4's. :param include: Array containing fields to include on response. :param exclude: Array containing fields to exclude on response. :param fields: Array containing fields to override d...
Method to delete ipv4's by their ids :param ids: Identifiers of ipv4's :return: None def delete(self, ids): """ Method to delete ipv4's by their ids :param ids: Identifiers of ipv4's :return: None """ url = build_uri_with_ids('api/v3/ipv4/%s/', ids) ...
Method to update ipv4's :param ipv4s: List containing ipv4's desired to updated :return: None def update(self, ipv4s): """ Method to update ipv4's :param ipv4s: List containing ipv4's desired to updated :return: None """ data = {'ips': ipv4s} i...
Method to create ipv4's :param ipv4s: List containing ipv4's desired to be created on database :return: None def create(self, ipv4s): """ Method to create ipv4's :param ipv4s: List containing ipv4's desired to be created on database :return: None """ d...
Method to search object group permissions general based on extends search. :param search: Dict containing QuerySets to find object group permissions general. :param include: Array containing fields to include on response. :param exclude: Array containing fields to exclude on response. :...
Method to delete object group permissions general by their ids :param ids: Identifiers of object group permissions general :return: None def delete(self, ids): """ Method to delete object group permissions general by their ids :param ids: Identifiers of object group permission...
Method to update object group permissions general :param ogpgs: List containing object group permissions general desired to updated :return: None def update(self, ogpgs): """ Method to update object group permissions general :param ogpgs: List containing object group permissio...
Method to create object group permissions general :param ogpgs: List containing vrf desired to be created on database :return: None def create(self, ogpgs): """ Method to create object group permissions general :param ogpgs: List containing vrf desired to be created on databas...
Method to search ipv6's based on extends search. :param search: Dict containing QuerySets to find ipv6's. :param include: Array containing fields to include on response. :param exclude: Array containing fields to exclude on response. :param fields: Array containing fields to override d...
Method to delete ipv6's by their ids :param ids: Identifiers of ipv6's :return: None def delete(self, ids): """ Method to delete ipv6's by their ids :param ids: Identifiers of ipv6's :return: None """ url = build_uri_with_ids('api/v4/ipv6/%s/', ids) ...
Method to create ipv6's :param ipv6s: List containing vrf desired to be created on database :return: None def create(self, ipv6s): """ Method to create ipv6's :param ipv6s: List containing vrf desired to be created on database :return: None """ data = ...
Inserts a new Option VIP and returns its identifier. :param tipo_opcao: Type. String with a maximum of 50 characters and respect [a-zA-Z\_-] :param nome_opcao_txt: Name Option. String with a maximum of 50 characters and respect [a-zA-Z\_-] :return: Following dictionary: :: ...
Change Option VIP from by the identifier. :param id_option_vip: Identifier of the Option VIP. Integer value and greater than zero. :param tipo_opcao: Type. String with a maximum of 50 characters and respect [a-zA-Z\_-] :param nome_opcao_txt: Name Option. String with a maximum of 50 characters a...
Remove Option VIP from by the identifier. :param id_option_vip: Identifier of the Option VIP. Integer value and greater than zero. :return: None :raise InvalidParameterError: Option VIP identifier is null and invalid. :raise OptionVipNotFoundError: Option VIP not registered. :...
Get all Option VIP by Environment Vip. :return: Dictionary with the following structure: :: {‘option_vip’: [{‘id’: < id >, ‘tipo_opcao’: < tipo_opcao >, ‘nome_opcao_txt’: < nome_opcao_txt >}, ... too option vips ...] } :raise EnvironmentVipNotFoundError: E...
Create a relationship of OptionVip with EnvironmentVip. :param id_option_vip: Identifier of the Option VIP. Integer value and greater than zero. :param id_environment_vip: Identifier of the Environment VIP. Integer value and greater than zero. :return: Following dictionary :: ...
Buscar nome_opcao_txt das Opcoes VIp quando tipo_opcao = 'Timeout' pelo environmentvip_id :return: Dictionary with the following structure: :: {‘timeout_opt’: ‘timeout_opt’: <'nome_opcao_txt'>} :raise InvalidParameterError: Environment VIP identifier is null and invalid. :...
Search rules ​by environmentvip_id :return: Dictionary with the following structure: :: {'name_rule_opt': [{'name_rule_opt': <name>, 'id': <id>}, ...]} :raise InvalidParameterError: Environment VIP identifier is null and invalid. :raise EnvironmentVipNotFoundError: Enviro...
Search healthcheck ​by environmentvip_id :return: Dictionary with the following structure: :: {'healthcheck_opt': [{'name': <name>, 'id': <id>},...]} :raise InvalidParameterError: Environment VIP identifier is null and invalid. :raise EnvironmentVipNotFoundError: Environm...
Search id of Option VIP when tipo_opcao = 'Retorno de trafego' ​​ :return: Dictionary with the following structure: :: {‘trafficreturn_opt’: ‘trafficreturn_opt’: <'id'>} :raise InvalidParameterError: Environment VIP identifier is null and invalid. :raise EnvironmentVipNot...
List all Model by Brand. :param id_brand: Identifier of the Brand. Integer value and greater than zero. :return: Dictionary with the following structure: :: {‘model’: [{‘id’: < id >, ‘nome’: < nome >, ‘id_marca’: < id_marca >}, ... too Model ...]} ...
Inserts a new Model and returns its identifier :param id_brand: Identifier of the Brand. Integer value and greater than zero. :param name: Model name. String with a minimum 3 and maximum of 100 characters :return: Dictionary with the following structure: :: {'model': {'id...
Change Model from by the identifier. :param id_model: Identifier of the Model. Integer value and greater than zero. :param id_brand: Identifier of the Brand. Integer value and greater than zero. :param name: Model name. String with a minimum 3 and maximum of 100 characters :return: Non...
Remove Model from by the identifier. :param id_model: Identifier of the Model. Integer value and greater than zero. :return: None :raise InvalidParameterError: The identifier of Model is null and invalid. :raise ModeloEquipamentoNaoExisteError: Model not registered. :raise Mod...
List all interfaces of an equipment. :param id_equipamento: Equipment identifier. :return: Dictionary with the following: :: {'interface': [{'protegida': < protegida >, 'nome': < nome >, 'id_ligacao_front': < id_ligacao_front >, 'id...
Get an interface by id. :param id_interface: Interface identifier. :return: Following dictionary: :: {'interface': {'id': < id >, 'interface': < interface >, 'descricao': < descricao >, 'protegida': < protegida >, 'tipo_equip': < id...
Insert new interface for an equipment. :param nome: Interface name. :param protegida: Indication of protected ('0' or '1'). :param descricao: Interface description. :param id_ligacao_front: Front end link interface identifier. :param id_ligacao_back: Back end link interface iden...
Edit an interface by its identifier. Equipment identifier is not changed. :param nome: Interface name. :param protegida: Indication of protected ('0' or '1'). :param descricao: Interface description. :param id_ligacao_front: Front end link interface identifier. :param i...
Remove an interface by its identifier. :param id_interface: Interface identifier. :return: None :raise InterfaceNaoExisteError: Interface doesn't exist. :raise InterfaceError: Interface is linked to another interface. :raise InvalidParameterError: The interface identifier is i...
Remove a connection between two interfaces :param id_interface: One side of relation :param back_or_front: This side of relation is back(0) or front(1) :return: None :raise InterfaceInvalidBackFrontError: Front or Back of interfaces not match to remove connection :raise Invali...
List interfaces linked to back and front of specified interface. :param nome_interface: Interface name. :param id_equipamento: Equipment identifier. :return: Dictionary with the following: :: {'interfaces':[ {'id': < id >, 'interface': < nome >, 'd...
List all Permission. :return: Dictionary with the following structure: :: {'perms': [{ 'function' < function >, 'id': < id > }, ... more permissions ...]} :raise DataBaseError: Networkapi failed to access the database. :raise XMLError: Networkapi failed to generate the XM...
Method to search ipv4's based on extends search. :param search: Dict containing QuerySets to find ipv4's. :param include: Array containing fields to include on response. :param exclude: Array containing fields to exclude on response. :param fields: Array containing fields to override d...
Method to delete ipv4's by their ids :param ids: Identifiers of ipv4's :return: None def delete(self, ids): """ Method to delete ipv4's by their ids :param ids: Identifiers of ipv4's :return: None """ url = build_uri_with_ids('api/v4/ipv4/%s/', ids) ...
Method to create ipv4's :param ipv4s: List containing ipv4's desired to be created on database :return: None def create(self, ipv4s): """ Method to create ipv4's :param ipv4s: List containing ipv4's desired to be created on database :return: None """ d...
Realiza a inserção ou alteração de um grupo virtual para o sistema de Orquestração de VM. :param equipamentos: Lista de equipamentos gerada pelo método "add_equipamento" da classe "EspecificacaoGrupoVirtual". :param vips: Lista de VIPs gerada pelo método "add_vip" da classe "EspecificacaoGrup...
Remove o provisionamento de um grupo virtual para o sistema de Orquestração VM. :param equipamentos: Lista de equipamentos gerada pelo método "add_equipamento_remove" da classe "EspecificacaoGrupoVirtual". :param vips: Lista de VIPs gerada pelo método "add_vip_remove" da classe "Especificacao...
List all users and their user groups. is_more -If more than 3 of groups of users or no, to control expansion Screen. :return: Dictionary with the following structure: :: {'usuario': [{'nome': < nome >, 'id': < id >, 'pwd': < pwd >, 'user': < us...
Get user by the ldap name. is_more -If more than 3 of groups of users or no, to control expansion Screen. :return: Dictionary with the following structure: :: {'usuario': [{'nome': < nome >, 'id': < id >, 'pwd': < pwd >, 'user': < user >, ...
Inserts a new User and returns its identifier. The user will be created with active status. :param user: Username. String with a minimum 3 and maximum of 45 characters :param pwd: User password. String with a minimum 3 and maximum of 45 characters :param name: User name. String with a ...
Change User from by the identifier. :param id_user: Identifier of the User. Integer value and greater than zero. :param user: Username. String with a minimum 3 and maximum of 45 characters :param password: User password. String with a minimum 3 and maximum of 45 characters :param nome: ...
Change password of User from by the identifier. :param id_user: Identifier of the User. Integer value and greater than zero. :param user_current_password: Senha atual do usuário. :param password: Nova Senha do usuário. :return: None :raise UsuarioNaoExisteError: User not regis...
Get user by username and password and their permissions. :param username: Username. String with a minimum 3 and maximum of 45 characters :param password: User password. String with a minimum 3 and maximum of 45 characters :return: Following dictionary: :: {'user': {'id': ...
Get user by username and password and their permissions. :param username: Username. String with a minimum 3 and maximum of 45 characters :param password: User password. String with a minimum 3 and maximum of 45 characters :return: Following dictionary: :: {'user': {'id': ...
List all access types. :return: Dictionary with structure: :: {‘tipo_acesso’: [{‘id’: < id >, ‘protocolo’: < protocolo >}, ... other access types ...]} :raise DataBaseError: Networkapi failed to access the database. :raise XMLError: Networkapi failed to genera...
Insert new access type and returns its identifier. :param protocolo: Protocol. :return: Dictionary with structure: {‘tipo_acesso’: {‘id’: < id >}} :raise ProtocoloTipoAcessoDuplicadoError: Protocol already exists. :raise InvalidParameterError: Protocol value is invalid or none. ...
Edit access type by its identifier. :param id_tipo_acesso: Access type identifier. :param protocolo: Protocol. :return: None :raise ProtocoloTipoAcessoDuplicadoError: Protocol already exists. :raise InvalidParameterError: Protocol value is invalid or none. :raise TipoA...
Removes access type by its identifier. :param id_tipo_acesso: Access type identifier. :return: None :raise TipoAcessoError: Access type associated with equipment, cannot be removed. :raise InvalidParameterError: Protocol value is invalid or none. :raise TipoAcessoNaoExisteErro...
Inserts a new Script Type and returns its identifier. :param type: Script Type type. String with a minimum 3 and maximum of 40 characters :param description: Script Type description. String with a minimum 3 and maximum of 100 characters :return: Dictionary with the following structure: ...
Change Script Type from by the identifier. :param id_script_type: Identifier of the Script Type. Integer value and greater than zero. :param type: Script Type type. String with a minimum 3 and maximum of 40 characters :param description: Script Type description. String with a minimum 3 and maxi...
Remove Script Type from by the identifier. :param id_script_type: Identifier of the Script Type. Integer value and greater than zero. :return: None :raise InvalidParameterError: The identifier of Script Type is null and invalid. :raise TipoRoteiroNaoExisteError: Script Type not regist...
Method to return list object pool by environment vip id Param environment_vip_id: environment vip id Return list object pool def pool_by_environmentvip(self, environment_vip_id): """ Method to return list object pool by environment vip id Param environment_vip_id: environment vi...
Method to return object pool by id Param pool_id: pool id Returns object pool def pool_by_id(self, pool_id): """ Method to return object pool by id Param pool_id: pool id Returns object pool """ uri = 'api/v3/pool/%s/' % pool_id return super(Api...
Method to return object pool by id Param pool_id: pool id Returns object pool def get_pool_details(self, pool_id): """ Method to return object pool by id Param pool_id: pool id Returns object pool """ uri = 'api/v3/pool/details/%s/' % pool_id re...
Method to search pool's based on extends search. :param search: Dict containing QuerySets to find pool's. :param include: Array containing fields to include on response. :param exclude: Array containing fields to exclude on response. :param fields: Array containing fields to override d...
Method to delete pool's by their ids :param ids: Identifiers of pool's :return: None def delete(self, ids): """ Method to delete pool's by their ids :param ids: Identifiers of pool's :return: None """ url = build_uri_with_ids('api/v3/pool/%s/', ids) ...
Method to update pool's :param pools: List containing pool's desired to updated :return: None def update(self, pools): """ Method to update pool's :param pools: List containing pool's desired to updated :return: None """ data = {'server_pools': pools} ...
Method to create pool's :param pools: List containing pool's desired to be created on database :return: None def create(self, pools): """ Method to create pool's :param pools: List containing pool's desired to be created on database :return: None """ d...
Find reals related with equipment :param id_equip: Identifier of equipment :return: Following dictionary: :: {'vips': [{'port_real': < port_real >, 'server_pool_member_id': < server_pool_member_id >, 'ip': < ip >, 'port_vip': < port_vip >, ...
Find vlans by all search parameters :param name: Filter by vlan name column :param iexact: Filter by name will be exact? :param environment: Filter by environment ID related :param equip_type: Filter by equipment_type ID related :param group: Filter by equipment group ID related...
Inserts a new Equipment and returns its identifier Além de inserir o equipamento, a networkAPI também associa o equipamento ao grupo informado. :param name: Equipment name. String with a minimum 3 and maximum of 30 characters :param id_equipment_type: Identifier of the Equipment Type. ...
Change Equipment from by the identifier. :param id_equip: Identifier of the Equipment. Integer value and greater than zero. :param nome: Equipment name. String with a minimum 3 and maximum of 30 characters :param id_tipo_equipamento: Identifier of the Equipment Type. Integer value and greater t...
Aloca um IP em uma VLAN para um equipamento. Insere um novo IP para a VLAN e o associa ao equipamento. :param id_vlan: Identificador da vlan. :param id_equipamento: Identificador do equipamento. :param descricao: Descriçao do IP. :return: Dicionário com a seguinte estrutura: ...
Allocate an IP on a network to an equipment. Insert new IP for network and associate to the equipment :param id_network_ipv4: ID for NetworkIPv4. :param id_equipamento: ID for Equipment. :param descricao: Description for IP. :return: Following dictionary: :: ...
Allocate an IP on a network to an equipment. Insert new IP for network and associate to the equipment :param id_network_ipv6: ID for NetworkIPv6. :param id_equip: ID for Equipment. :param description: Description for IP. :return: Following dictionary: :: {...
Removes association of IP and Equipment. If IP has no other association with equipments, IP is also removed. :param id_equipamento: Equipment identifier :param id_ip: IP identifier. :return: None :raise VipIpError: Ip can't be removed because there is a created Vip Request. ...
Associates an IPv6 to a equipament. :param id_equip: Identifier of the equipment. Integer value and greater than zero. :param id_ipv6: Identifier of the ip. Integer value and greater than zero. :return: Dictionary with the following structure: {'ip_equipamento': {'id': < id_ip_do_e...
Lista os equipamentos de um tipo e que estão associados a um ambiente. :param id_tipo_equipamento: Identificador do tipo do equipamento. :param id_ambiente: Identificador do ambiente. :return: Dicionário com a seguinte estrutura: :: {'equipamento': [{'id': < id_equipament...
Obtém um equipamento a partir do seu nome. :param nome: Nome do equipamento. :return: Dicionário com a seguinte estrutura: :: {'equipamento': {'id': < id_equipamento >, 'nome': < nome_equipamento >, 'id_tipo_equipamento': < id_tipo_equipamento >, ...
Obtém um equipamento a partir do seu identificador. :param id: ID do equipamento. :return: Dicionário com a seguinte estrutura: :: {'equipamento': {'id': < id_equipamento >, 'nome': < nome_equipamento >, 'id_tipo_equipamento': < id_tipo_equipamento >, ...
Return all equipments in database :return: Dictionary with the following structure: :: {'equipaments': {'name' :< name_equipament >}, {... demais equipamentos ...} } :raise DataBaseError: Networkapi failed to access the database. :raise XMLError: Networkapi failed to gene...
Return all equipments in database :return: Dictionary with the following structure: :: {'equipaments': {'name' :< name_equipament >}, {... demais equipamentos ...} } :raise DataBaseError: Networkapi failed to access the database. :raise XMLError: Networkapi failed to gener...
Remove um equipamento a partir do seu identificador. Além de remover o equipamento, a API também remove: - O relacionamento do equipamento com os tipos de acessos. - O relacionamento do equipamento com os roteiros. - O relacionamento do equipamento com os IPs. -...
Associa um equipamento a um grupo. :param id_equipamento: Identificador do equipamento. :param id_grupo_equipamento: Identificador do grupo de equipamento. :return: Dicionário com a seguinte estrutura: {'equipamento_grupo':{'id': < id_equip_do_grupo >}} :raise GrupoEquipam...
Remove a associação de um equipamento com um grupo de equipamento. :param id_equipamento: Identificador do equipamento. :param id_grupo: Identificador do grupo de equipamento. :return: None :raise EquipamentoGrupoNaoExisteError: Associação entre grupo e equipamento não cadastrada. ...
Search Group Equipment from by the identifier. :param id_egroup: Identifier of the Group Equipment. Integer value and greater than zero. :return: Dictionary with the following structure: :: {'equipaments': [{'nome': < name_equipament >, 'grupos': < id_group >, ...
Search Group Equipment from by the identifier. :param id_egroup: Identifier of the Group Equipment. Integer value and greater than zero. :return: Dictionary with the following structure: :: {'equipaments': [{'nome': < name_equipament >, 'grupos': < id_group >, ...
Sends a GET request. @param uri: Uri of Service API. @param data: Requesting Data. Default: None @raise NetworkAPIClientError: Client failed to access the API. def get(self, uri): """ Sends a GET request. @param uri: Uri of Service API. ...
Parse data request to data from python. @param content: Context of request. @raise ParseError: def _parse(self, content): """ Parse data request to data from python. @param content: Context of request. @raise ParseError: """ if con...
Convert dict for URL params def prepare_url(self, uri, kwargs): """Convert dict for URL params """ params = dict() for key in kwargs: if key in ('include', 'exclude', 'fields'): params.update({ key: ','.join(kwargs.get(key)) ...
Create new Rack :param number: Number of Rack :return: Following dictionary: :: {'rack': {'id': < id_rack >, 'num_rack': < num_rack >, 'name_rack': < name_rack >, 'mac_sw1': < mac_sw1 >, 'mac_sw2': < mac_sw2 >, 'mac_ilo': < mac_ilo >, ...
Remove Rack by the identifier. :param id_rack: Identifier of the Rack. Integer value and greater than zero. :return: None :raise InvalidParameterError: The identifier of Rack is null and invalid. :raise RackNaoExisteError: Rack not registered. :raise RackError: Rack is associa...
Lista os ambientes filtrados conforme parâmetros informados. Se os dois parâmetros têm o valor None então retorna todos os ambientes. Se o id_divisao é diferente de None então retorna os ambientes filtrados pelo valor de id_divisao. Se o id_divisao e id_ambiente_logico são diferentes de...
Obtém um ambiente a partir do ip e nome de um equipamento. :param nome_equipamento: Nome do equipamento. :param ip_equipamento: IP do equipamento no formato XXX.XXX.XXX.XXX. :return: Dicionário com a seguinte estrutura: :: {'ambiente': {'id': < id_ambiente >, ...
Obtém um ambiente a partir da chave primária (identificador). :param id_ambiente: Identificador do ambiente. :return: Dicionário com a seguinte estrutura: :: {'ambiente': {'id': < id_ambiente >, 'link': < link >, 'id_divisao': < id_divisao >, '...
Get HealthCheck by id. :param id_healthcheck: HealthCheck ID. :return: Following dictionary: :: {'healthcheck_expect': {'match_list': < match_list >, 'expect_string': < expect_string >, 'id': < id >, 'ambiente': < ambiente >}} :rais...
Lista todos os ambientes por equipamento especifico. :return: Dicionário com a seguinte estrutura: :: {'ambiente': {'id': < id_ambiente >, 'link': < link >, 'id_divisao': < id_divisao >, 'nome_divisao': < nome_divisao >, 'id_ambiente_logico'...
Lista os healthcheck_expect´s de um ambiente. :param id_ambiente: Identificador do ambiente. :return: Dicionário com a seguinte estrutura: :: {'healthcheck_expect': [{'id': < id_healthcheck_expect >, 'expect_string': < expect_string >, 'match_list': < ma...
Insere um novo healthckeck_expect e retorna o seu identificador. :param expect_string: expect_string. :param id_ambiente: Identificador do ambiente lógico. :param match_list: match list. :return: Dicionário com a seguinte estrutura: {'healthcheck_expect': {'id': < id >}} :rais...
Insere um novo ambiente e retorna o seu identificador. :param id_grupo_l3: Identificador do grupo layer 3. :param id_ambiente_logico: Identificador do ambiente lógico. :param id_divisao: Identificador da divisão data center. :param id_filter: Filter identifier. :param link: Link...
Insert new environment with ip config and returns your id. :param id_l3_group: Layer 3 Group ID. :param id_logical_environment: Logical Environment ID. :param id_division: Data Center Division ID. :param id_filter: Filter identifier. :param id_ip_config: IP Configuration ID. ...
Makes relationship of environment with ip config and returns your id. :param id_environment: Environment ID. :param id_ip_config: IP Configuration ID. :return: Following dictionary: {'config_do_ambiente': {'id_config_do_ambiente': < id_config_do_ambiente >}} :raise InvalidPar...
Altera os dados de um ambiente a partir do seu identificador. :param id_ambiente: Identificador do ambiente. :param id_grupo_l3: Identificador do grupo layer 3. :param id_ambiente_logico: Identificador do ambiente lógico. :param id_divisao: Identificador da divisão data center. ...
Inserts a new healthckeck_expect with only expect_string. :param expect_string: expect_string. :return: Dictionary with the following structure: :: {'healthcheck_expect': {'id': < id >}} :raise InvalidParameterError: The value of expect_string is invalid. :raise...
Get all expect_string. :return: Dictionary with the following structure: :: {'healthcheck_expect': [ 'expect_string': < expect_string >, ... demais healthcheck_expects ...]} :raise InvalidParameterError: Identifier is null and invalid. :raise Da...
Get all distinct acl paths. :return: Dictionary with the following structure: :: {'acl_paths': [ < acl_path >, ... ]} :raise DataBaseError: Networkapi failed to access the database. :raise XMLError: Networkapi failed to generate the XML respons...
Set template value. If id_environment = 0, set '' to all environments related with the template name. :param id_environment: Environment Identifier. :param name: Template Name. :param network: IPv4 or IPv6. :return: None :raise InvalidParameterError: Invalid param. :ra...