Fixing api call issue constraints