2022 Sep 05 11:47 PM
Hi.
I'm having this error when trying call an API.
This is my code: (example URL)
lv_url = 'http://test.url.cl/api/v123/cl/emp?id=' && p_inv.
cl_http_client=>create_by_url( EXPORTING url = lv_url
IMPORTING client = lo_client
EXCEPTIONS OTHERS = 4 ).
lo_client->request->set_method( 'GET' ).
CALL METHOD lo_client->request->set_header_field
EXPORTING
name = 'auth_token'
value = 'Hc................Ak'.
lo_client->send( ).
lo_client->receive( ).
When execute 'RECEIVE' method, dumps:
--> Exception condition "HTTP_COMMUNICATION_FAILURE" raised.
I have this error in tx.SMICM:
--> [Thr 6924] *** ERROR => IcmConnConnect: No service for protocol HTTPS started [icxxconn.c 2441]
When I try with other URL, i.e.:
lv_url = 'http://httpbin.org/ip'.
lv_url = 'http://jsonplaceholder.typicode.com/users'.
This URL's works fine, without any error.
I don't know what I must check or change.
Thanks in advance.
2022 Sep 06 5:41 AM
I guess it's all about configuring and activating the HTTPS protocol in profile parameters and in SMICM > Services.
I can find many answers in the Web with below query. What did you try? What doesn't work?
icmConnConnect: No service for protocol HTTPS site:sap.com
2022 Sep 06 1:10 PM
This error can occur due to the lack of SMICM configuration or the restriction of the SAP Server to access the URL (most cases)
2022 Sep 06 1:35 PM
Hi!.
I'm trying to get Employees data with an API.
I don't know if it is HTTPS protocol configuration because with the others URL's works fine. I just have the error with one of them, using the same abap code.
lv_url = 'http://test.url.cl/api/v123/cl/emp'. --> ERROR
lv_url = 'http://httpbin.org/ip'. --> OK
lv_url = 'http://jsonplaceholder.typicode.com/users'. --> OK