code: public ApiResponse<RuleEnvelope> createRuleWithHttpInfo(RuleCreationInfo ruleInfo, String userId) throws ApiException {
          com.squareup.okhttp.Call call = createRuleValidateBeforeCall(ruleInfo, userId, null, null);
          Type localVarReturnType = new TypeToken<RuleEnvelope>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
docs: Create Rule
  Create a new Rule
  @param ruleInfo Rule object that needs to be added (required)
  @param userId User ID (required)
  @return ApiResponse&lt;RuleEnvelope&gt;
  @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body