MSTest has a TestInitialize attribute that you can use to initialize each test. In it you could put your Login. There is also a TestCleanup attribute. There you could put your LogOut. The Get and Create would have to be within one method in order to ensure that the Get always happens before the Create.
I am not familiar with SonarQube, so don't know whether it would handle this.