Change endpoint format from tuple to dict