Developers should refrain from using any non-sanctioned APIs in their Windows 8 Metro-style apps, Microsoft has said.
Developer experience manager John Hazen said on Thursday that using APIs not offered as part of the Metro software development kit (SDK) could undermine consumer confidence and make the apps break.
"Resist the temptation to find ways to invoke APIs that are not included in the SDK. This ultimately undermines the expectations that customers have for your app. APIs that are outside the SDK are not guaranteed to work with Metro style apps either in this release or in future releases, so you may find that your app doesn’t function properly for all customers," Hazen wrote in a blog post on creating reliable apps.
Hazen pointed out that outside APIs "may also not function properly" with the asynchronous functions that are key to the Metro-style app design. He also suggested that customer confidence may take a hit if apps access "resources and data that Metro-style apps would not normally interact with".
Hiding and obfuscating calls to APIs not included in the Metro SDK's set is a violation of store policy, Hazen said.
"In the end, we have created this platform to help developers like you to build amazing apps that work well with the system and with other apps and devices to delight customers. Working with the Metro style SDK is fundamental to your realising that goal," he added.
Technology journalist Tim Anderson noted that Hazen was admitting "crafty developers may find ways to escape the Metro sandbox, undermining both the security and privacy protection build into Metro".
He added that it would probably be more of a problem for the x86 version of Windows 8 than the Windows RT version, which is designed for ARM's architecture, as RT apps are more tightly controlled.