cancel
Showing results for 
Search instead for 
Did you mean: 

What is the meaning of @api for interface and only some of it's methods

What is the meaning of @api for interface and only some of it's methods

The interface \Magento\Customer\Api\AccountManagementInterface has the @api annotation.

My understanding is that the meaning of this is it's "stable" and a change to the interface will require a module version change according to the semantic versioning rules.

 

Now, what is confusing me is that *some* of the methods declared on the interface also are annotated with @api.

For example, \Magento\Customer\Api\AccountManagementInterface::createAccountWithPasswordHash() is annotated, but \Magento\Customer\Api\AccountManagementInterface::createAccount() is not.

 

I would expect that an @api annotation on an interface would cover **all** of the interface methods.

Is that true? If not, what does an @api annotation on an interface even mean, if the individual methods also have to be annotated to be considered "stable"?

 

-----
I learn