Washington works in mysterious ways, but James E. Webb's has never been one of them. As President Truman's budget director and Dean Acheson's undersecretary of state, and as the pilot of NASA during America's race with Russia to the moon, he declined to establish a "cult of personality." The result was that James E. Webb never became a household word. Now, at the age of 74, he has become instead a Washington legend.

Webb resigned one year short of the triumphant Apollo 11 moon landing, but he left behind a management legacy well remembered by those who seek to find how Washington works. In his own phrase: "You can't be namby-pamby about this stuff at all."

As chief of the National Aeronautics and Space Administration he used his power to the fullest, reveled in a blood-on-the-hands operating style, and that won him a reputation for bullheadedness. He maintained a keep-'em-off-balance management technique he called "planned disequilibrium" and an elaborate information network that fed him details that served as an early-warning system for errant personalities or vagrant programs. He didn't like to be second-guessed, but when called before Congress he buried committees with streams of data that ran up to 6,000 transcript pages each time he appeared.

Yet Webb was also a man who, as chief of a space program with 35,000 NASA employes and 400,000 contractors in 20,000 separate companies, turned down the limousine offered by the General Services Administration and made a black Checker cab his symbol during his seven-year tenure. As the highest-ranking visitor to a space conference in Kansas City in the early 1960s, he discovered that by oversight no room reservation had been made for him. Telling no one, he merely asked that a cot be set up in a hotel display room and prepared to bunk there. The head of NASA was quietly reading briefing papers on his cot when discovered there by his horrified staff.

This morning, Webb is to be at West Point, where he will receive the 1981 Sylvanus Thayer Award for public service, joining such distinguished recipients as Dwight D. Eisenhower, John Foster Dulles and Clare Boothe Luce. Despite a lifetime of downplaying his own career, he agreed to a chat earlier this week in his home near Observatory Circle, where a small dog cavorted on the rug and Mrs. Webb patrolled the back yard garden. Getting the Job

"It was 1961, and there had been an argument between the scientists and Vice President Lyndon Johnson about who should run NASA. They'd already gone through about 18 candidates. President Kennedy finally told Johnson, either you name somebody -- or I'll name him.

"Well, I found myself in Johnson's office, and Hugh Dryden was there. He was an outstanding administrator and the head of the National Advisory Committee for Aeronautics. I told him that frankly I didn't think I was right for the job, that they needed a scientist or an engineer. He agreed with me. He wanted the job himself. We got somebody to go in and tell Johnson that, but Johnson kicked him out. Remember, they'd already gone through 18 other candidates. I was told that the only guy who could get me off the hook was Clark Clifford. So I talked to Clifford, but Clifford said, 'Hey, wait a minute, I'm the one who recommended you.'

"Of course, Johnson was the one who was pushing me, but I had been around Washington long enough to know that it was the president that mattered; that if I was going to do this, I had to be the president's appointment.

"So Johnson took me over to Kennedy's office. He was left outside and I went in alone. I told Kennedy what I believed: that he needed a scientist to run the space program. But Kennedy said no, he wanted a policy maker, and I was it. He got up immediately and led me the back way to Pierre Salinger's office. He told Salinger to make the announcement of my appointment then and there. He wouldn't even permit Johnson and Dryden to be told first. The Hoops of Iron

"Now the way I saw it, my job was to bring together three men: Dryden, who was the thorough professional; Robert Seamans, who'd been named by a Republican and would be my other deputy, and me -- the new Democratic appointee.

"We needed to work together, so here's what I decided: No policy would be approved for NASA until the three of us had talked it over. None of us would do violence to the strongly held opinions of the other. This was a policy which intentionally put us in chains. We bound ourselves in these hoops of iron.

"Sure, I could have overruled them. I was the boss. But it wouldn't have worked that way.

"In addition to the iron-hoops policy, we developed a procurement policy: Any contract over $5 million had to be okayed by the three of us. Some thought this politically dangerous, because we were taking on the onus of approval. But no, we were establishing a relationship of confidence. It meant that program managers like Wernher von Braun and others, strong men, knew they had to appear and tell us what they were doing. And be questioned. But the result was that while we were judging them, they were also judging us." Get What You Want

"One thing I knew was that if this was going to be a national project, it had to engage the best people in the nation. We needed a large number of trained people, and at the time only Cal Tech, MIT and Harvard were really turning them out. So we went to the University of Chicago and said, 'How'd you like to double your graduate school for scientists and engineers?'

"I was, in effect, offering to train 1,000 PhD's a year out of the NASA budget. I told President Kennedy I would get the program started by transferring funds from here and there, and then after the program had been going for a while his budget director was going to call him on it.

" 'What happens then?' Kennedy asked me.

" 'Then you'll have to challenge me on it,' I told him. The point is you have to go as far as you can go. You have to be an activist." Protecting the Turf

There were great political opportunities in the space program, but Webb was extremely protective of them. The president had given the nation a goal -- the moon -- and the goal was all that mattered to him. There came a time, however, when it was suggested that perhaps a certain region could benefit from NASA's largess.

"Well, Kennedy thought part of his job was to provide employment in cities," Webb explained. "And although he himself never put any pressure on me, some of his friends did 'build on that understanding.'

"My response was to explain that there were probably 50 men in Washington who would do anything the president wanted, and they could easily get one of them for my job."

The response took the form of a memo, a blistering memo from Webb to Ken O'Donnell, Kennedy's aide and confidant, that said essentially: You run the White House, I'll run NASA. And the memo stuck.

"You know, Kennedy wasn't one to praise you," Webb said. Most of the contact he had with me was over complaints. I saw him last about three weeks before he was killed. I said, 'Are you going to stand up for me next year when the going gets tough on the budget?' He said yes. Then he added, 'You know, I appreciate what you're doing. But I don't want to know how you're doing it.' "

Later, Webb would bump shoulders with Vice President Hubert H. Humphrey. Humphrey was planning to make certain NASA announcements himself, but Webb bristled at the idea of "Minnesota getting into the act.

"I went in and told Johnson, 'I'm having some trouble with your vice president.' And that was that. Knowledge Is Power

Webb was known throughout his tenure as a man who, despite the boggling scope of the lunar project, had an uncanny specific knowledge of small wrinkles in the NASA blanket. His goal was not smooth sailing but flexibility and achievement, so he juggled personnel frequently under his policy of "planned disequilibrium." Equilibrium was bad because it was static; the space program continually scheduled solutions to unsolved problems, committing huge sums to technological breakthroughs that hadn't come yet. Since the answers were not possible to know, Webb had to be able to decide "who could get the answer. His personal-information network provided him with data that ranged from management slip-ups at far remove to the fact that an employe's child was sick.

"The nervous center for that was the decision-making process itself," he said. "I wanted people I could trust looking at all the paper that came in, the decision-making routine. There's where you learn how a man was doing his job. In any situation, some people will cooperate 100 percent with you. Others, you find, are leaning on you to make the decisions for them. Still others are trying to go around you, bending everything to get their own way.

"I wanted a free flow of information. I wanted to be able to call the man who had the answer, no matter how far down the line he was. I didn't call his boss first. Individuals could talk to me. For example, I would not let a manager like Wernher von Braun issue his own table-of-organization chart. That's a simple little thing. But word got around. It was a sort of check and a balance." Taking the Heat

"I decided a long time ago never to answer criticism in public. You can get away with that if you have nothing to hide, if you've been honest. After the fire the cockpit fire that killed three astronauts on the launch pad in 1967 , when I was being criticized, particularly by one or two senators, I demanded a closed session of the Senate. That was, of course, the last thing my detractors wanted -- a private session. But we sat down, with the doors closed. And the first senator to speak up was Sen. Brooke of Massachusetts, who got it all out on the table. And I corrected them where they were wrong." A Time to Go

Webb resigned his job as NASA chief in 1968, a year before the first manned lunar landing. The front pages reported that he was bitter about budget cuts by the Johnson administration, increasingly beset with the funding of the Vietnam war. Sen. Margaret Chase Smith of Maine claimed that LBJ had "pulled the rug out from under James E. Webb."

"It wasn't a question of money," Webb said, revealing a conversation with Lyndon Baines Johnson that gave him a bit of political foresight nine months ahead of the times.

"President Johnson told me in July 1967 that he wasn't planning to run for another term. Yes, he told me that. I don't know what he told other people, but that's what he told me. He also said he was telling Texas Gov. John Connally. And he said he was going to make a public announcement in August. But, of course, it took him until the next March before he actually did.

"I knew that whoever got elected, either Humphrey or Nixon, wouldn't be happy with me. They might keep me on, but not be happy. By resigning, I could at least show them that it wasn't child's play, what the nation was trying to do with these big rockets." In the Garden

Webb's speech for the Sylvanus Thayer Award is 10 minutes long. In it, he tells the cadets that they, too, will one day be called on to administer large endeavors like "Apollo, based on pushing knowledge and technology to its limits, and requiring skillful leadership that takes into account social, economic and political, as well as technical factors"; and that they too will become part of "the large national projects in which success or failure will determine our destiny." An old friend, Gen. Harris Hull, dropped by to show Webb the small American flag Webb would present to the academy today. The flag made the moon trip with Apollo 11. Twice Webb made it clear that the flag is not his personal property. The gift is really "from one government agency to another."

Webb calls Hull "General," and Hull calls him Mr. Webb. They both got down on hands and knees on the living room rug to rewrap the presentations after admiring them. A courtly dispute then occurred about who had the Scotch tape. This was followed by Mr. Webb's insistence on driving Gen. Hull home, but despite the dulcet tones of Mr. Webb's home state of North Carolina, the battle of courtesy was won by Gen. Hull, who got his wife to come pick him up. After a final gentlemanly skirmish over who should carry the presentations to West Point, Gen. Hull left before Webb could play his trump card -- a dinner invitation.

Webb, as if revealed, sought to explain:

"I was a Marine aviator when Gen. Hull was a newspaperman, and he wanted to see the Potomac in flood. We went down to the Anacostia Field, which was flooding, and they gave me a plane to take over to College Park, which was high ground. So the two of us took off. It was only after we got in the air that I looked at the fuel gage and realized the plane had no gas. So we turned back, but the runway was already covered with water. We landed just like a seaplane, got some fuel and took off again. So you see, we go way back."

Then the bullheaded, aggressive, savvy, don't-get-in-my-way, blood-on-the-hands Washington administrator of the 1940s and then the 1960s went out to sit in his garden. It is said that for all his single-mindedness, James E. Webb never really had an ego. He was more concerned about the job at hand than the hand doing the job, and that went for himself, too. "You like to give credit," he said. "That's what gets it done."

But -- most people also ask a little credit for themselves.

"Somewhere along the line I got 32 honorary doctorates," he replied. "I didn't ask for any of them."

And Washington, Mr. Webb. Has Washington learned anything over the years?

"There are so many new people . . ." he replied, letting the sentence trail off into an allegedly uncharacteristic smile.