"We were told we had to stay indoors and that we weren't allowed to go near the windows."
Another student said the dogs barked at two of his friends.
"So my friends told the dogs to go away and shouted at the dogs. Then I think the dogs started to chase them because when they came into the class they were puffing."
An Auckland Council animal control officer and four police officers arrived at the school shortly afterwards to search for the dogs.
The officers spent more than an hour looking for the dogs in the school grounds, and also patrolled neighbouring streets.
The school remained in lockdown for about 30 minutes.
The boy's father arrived at the school at 3pm to find the school gates chained up. He said about 20 parents were standing around wondering what had happened.
The boy's mother said the school did not send a text message and email to parents until 4.15pm, which she described as "a bit odd".
"I thought they would have told us before or while it was happening, rather than after it was all over."
The message said: "Lockdown at school due to two vicious dogs on school grounds. A teacher was attacked."
Blockhouse Bay Intermediate did not respond to the Herald's request for comment before deadline.
Its acting principal, Ngaria Stephenson, said on Facebook: "We would like to thank the police and Dog Control who supported our school during a lockdown this afternoon at approximately 2.50pm.
"All students exited the school in a calm and responsible manner at approximately 3.30pm. We are extremely proud of our teachers, students and parents who acted in a professional and calm manner."
As of 6pm yesterday, the dogs had not been found.
Anyone with any information about the dogs can contact Auckland Council on 09 301-0101.