To get the table definition.

describe foo;

To get the constraints of a table.

select * from user_constraints where table_name='foo';