《API设计优先-不仅仅是另一个漂亮的接口.pdf》由会员分享,可在线阅读,更多相关《API设计优先-不仅仅是另一个漂亮的接口.pdf(32页珍藏版)》请在三个皮匠报告上搜索。
1、#CiscoLive#CiscoLiveDavid Staudt,DevNet Developer AdvocatedstaudtatciscoDEVNET-2092Not Just Another Pretty InterfaceAPI Design First 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveEnter your personal notes hereCisco Webex App 3Questions?Use Cisco Webex App to chat with th
2、e speaker after the sessionFind this session in the Cisco Live Mobile AppClick“Join the Discussion”Install the Webex App or go directly to the Webex spaceEnter messages/questions in the Webex spaceHowWebex spaces will be moderated by the speaker until June 9,2023.12343https:/ 2023 Cisco and/or its a
3、ffiliates.All rights reserved.Cisco PublicDEVNET-2092David StaudtDevNet Developer AdvocateCisco Systems Inc.Supporting and advocating on-behalf-of Cisco API developers for over 20 yearsCovering Security,Collaboration,and Customer Experience APIsAgenda 2023 Cisco and/or its affiliates.All rights rese
4、rved.Cisco PublicWhy Design APIs?OpenAPI SpecificationDesign ToolsDocumentation Auto-GenerationSDK Auto-GenerationCiscos API JourneyAPI InsightsDEVNET-20925Why Design APIs?2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveAPIsHow 2 integr8?DuhDEVNET-20927 2023 Cisco and/or i
5、ts affiliates.All rights reserved.Cisco Public#CiscoLiveMicroservices ArchitectureDEVNET-20928 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveAnonymous-All teams will henceforth expose their data and functionality through service interfaces.There will be no other form of
6、interprocess communication allowed:no direct linking,no direct reads of another teams data store,no shared-memory model.All service interfaces must be designed from the ground up to be externalizable.Anyone who doesnt do this will be fired.Thank you;have a nice day!9DEVNET-2092APIsbaby!Why Design AP
7、Is First?2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLive11DEVNET-2092 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveMock ServerAPI SpecImplementationDocumentationClient LibrariesDEVNET-209212 2023 Cisco and/or its affiliates.All rights reserve
8、d.Cisco Public#CiscoLiveThe OpenAPI Initiative Charterhttps:/www.openapis.org/13DEVNET-2092 2023 Cisco and/or its affiliates.All rights reserved.Cisco PublicElements of OASInfo:Info:Provides details about the API,including a title and descriptionSecuritySecurity:Specifies authorization.Required for
9、interactive documentationPaths:Paths:What the API can do.Defined by a path+HTTP method(aka verb)+input parameters+one or more response detailsComponents:Components:Capture reusable elements that may be referenced within and across OAS files.Includes schema,headers,security detailsDEVNET-209214Demo 2
10、023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveOAS Document LifecycleProduct ManagerOAS Documentdraft 1Engineering LeadTech Writer1.Create initial OAS document2.Expand OAS document with payload and errors3.Enrich OAS documents with descriptions and OAS Documentdraft 2OAS D
11、ocumentdraft 4.Integrate with API documentation publishing toolDEVNET-209216Ciscos API Quality Journey 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveCiscos API Quality JourneyPast:(sometimes wildly)different APIs per team-acquisitionsPresent:Focus on REST/OAuth compile A
12、PI GuidelinesFuture:Consistent APIs/Docs/Tools(the dream)DEVNET-209218 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveCiscos API Quality JourneyAdvisingAdvisingDevNets API Architect API Architect Stve Sfartz Stve Sfartz begins outreach to engineering teams providing guida
13、nce based on the Style GuideInceptionInceptionDevNet DevNet creates Cisco Cisco API Advisory GroupAPI Advisory Group with 10 engineering membersEducationEducationThe Cisco API Style Cisco API Style Guide Guide is released between 2018-2019 based on feedback from 20 engineering teamsImplementingImple
14、mentingWork begins with Cisco API Champions designated across BEs.Cisco API GuidelinesCisco API Guidelines(based on the Style Guide)used to drive quality standards.Cisco APICisco API Guidelines Guidelines DevNet API Experience WorkshopsDevNet API Experience WorkshopsCisco API Style GuideCisco API St
15、yle Guide200212022Working with Product Engineering TeamsExecutive PrioritizationExec AlignmentExec AlignmentAPI Quality prioritized in DevRel Strategy.DevRel drove awareness of broadspanning API quality issues,alignment with ELT Engr to prioritizeDEVNET-209219 2023 Cisco and/or its affili
16、ates.All rights reserved.Cisco Public#CiscoLiveCiscos API-first StrategyTreat APIs as ProductVersioned releasesAPI ChangelogsBackwards CompatibilityDocumentationSupportAnnounced at Partner SummitBackward compatible Backward compatible as of October 2022as of October 2022Meraki Dashboard API v1ISE AP
17、I v1XDR ThreatResponse API v1Cloud Security Open APIs v2Webex API v1PX Cloud API v120DEVNET-1346 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveAPI Guidelines Lessons LearnedAPIs are real products-plan for serviceability,training,support,managementDesign deliberately-simp
18、licity,consistency,loose-coupling,evolve-abilityAPIs are forever-invest in making the 1.0 version the only versionDeveloper experience counts-docs,training,tools,support,managementSecurity/Privacy are must do-Guidelines now part of CPDMDEVNET-209221API Analytics Tools 2023 Cisco and/or its affiliate
19、s.All rights reserved.Cisco Public#CiscoLiveApplication DeveloperDevOpsStatic AnalysisAPI GovernanceLanguage InclusivityIDE Extension:VS CodeKey FeaturesKey FeaturesPanopticaThe Cisco Secure Application CloudDynamic AnalysisDriftZombie&ShadowSpec ReconstructionDevSecOpsOpen SourceOpen SourceSaaSCont
20、ainer ScanningSecuring APIs on Kubernetes ClustersInternal/External facing API usageAPI Policy EnforcementKey FeaturesDEVNET-209223 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveAPI Insights Validate and Score APIs24DEVNET- Cisco and/or its affiliates.All rights reserved
21、.Cisco Public#CiscoLiveAPI Clarity-OAS vs.live traffic observations25DEVNET-2092www.apiclarity.io 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLivePanoptica-Cloud-native application security26DEVNET-2092www.panoptica.app 2023 Cisco and/or its affiliates.All rights reserved.
22、Cisco Public#CiscoLiveLinks&ResourcesOpen API SpecificationSwagger EditorSwagger UI(docs)Swagger CodegenAPI Stylebook(collection of API style guides)DEVNET-209227 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLiveFill out your session surveys!Attendees who fill out a minimum
23、 of four session surveys and the overall event survey will get Cisco Live-branded socks(while supplies last)!28DEVNET-2092These points help you get on the leaderboard and increase your chances of winning daily and grand prizesAttendees will also earn 100 points in the Cisco Live Challenge for every
24、survey completed.2023 Cisco and/or its affiliates.All rights reserved.Cisco PublicContinue your educationBRKDEVBRKDEV-22492249 18 Facets of the OpenAPI StandardDEVNET 2158 DEVNET 2158 API Middle-Tier for DummiesDEVWKSDEVWKS-10171017 Improve OpenAPI Specs with API InsightsDEVWKSDEVWKS-30023002 API Se
25、curity with Panoptica29DEVNET-2092Thank you#CiscoLive 2023 Cisco and/or its affiliates.All rights reserved.Cisco Public#CiscoLive31Gamify your Cisco Live experience!Get points Get points for attending this session!for attending this session!Open the Cisco Events App.Click on Cisco Live Challenge in the side menu.Click on View Your Badges at the top.Click the+at the bottom of the screen and scan the QR code:How:123431 2023 Cisco and/or its affiliates.All rights reserved.Cisco PublicDEVNET-2092#CiscoLive